#include <CameraMobile.h>
Public Member Functions | |
void | addEnvSensor (int type, float value) |
CameraMobile (bool smoothing=false) | |
virtual void | close () |
const CameraModel & | getCameraModel () const |
const Transform & | getDeviceTColorCamera () const |
const cv::Mat & | getOcclusionImage (CameraModel *model=0) const |
const Transform & | getOriginOffset () const |
ScreenRotation | getScreenRotation () const |
virtual std::string | getSerial () const |
GLuint | getTextureId () |
void | getVPMatrices (glm::mat4 &view, glm::mat4 &projection) const |
virtual bool | init (const std::string &calibrationFolder=".", const std::string &cameraName="") |
virtual bool | isCalibrated () const |
void | poseReceived (const Transform &pose) |
void | resetOrigin () |
void | setData (const SensorData &data, const Transform &pose, const glm::mat4 &viewMatrix, const glm::mat4 &projectionMatrix, const float *texCoord) |
void | setGPS (const GPS &gps) |
void | setOcclusionImage (const cv::Mat &image, const CameraModel &model) |
virtual void | setScreenRotationAndSize (ScreenRotation colorCameraToDisplayRotation, int width, int height) |
void | setSmoothing (bool enabled) |
void | spinOnce () |
bool | uvsInitialized () const |
const float * | uvsTransformed () const |
virtual | ~CameraMobile () |
Public Member Functions inherited from rtabmap::Camera | |
float | getImageRate () const |
const Transform & | getLocalTransform () const |
virtual bool | getPose (double stamp, Transform &pose, cv::Mat &covariance) |
bool | initFromFile (const std::string &calibrationPath) |
virtual bool | odomProvided () const |
void | resetTimer () |
void | setImageRate (float imageRate) |
void | setLocalTransform (const Transform &localTransform) |
SensorData | takeImage (CameraInfo *info=0) |
virtual | ~Camera () |
Public Member Functions inherited from UThread | |
Handle | getThreadHandle () const |
unsigned long | getThreadId () const |
bool | isCreating () const |
bool | isIdle () const |
bool | isKilled () const |
bool | isRunning () const |
void | join (bool killFirst=false) |
void | kill () |
void | setAffinity (int cpu=0) |
void | setPriority (Priority priority) |
void | start () |
UThread (Priority priority=kPNormal) | |
virtual | ~UThread () |
Public Member Functions inherited from UThreadC< void > | |
int | Create (Handle *const &H=0, const bool &CreateDetached=false, const unsigned int &StackSize=0, const bool &CancelEnable=false, const bool &CancelAsync=false) const |
int | Create (Handle *const &H=0, const bool &CreateDetached=false, const unsigned int &StackSize=0, const bool &CancelEnable=false, const bool &CancelAsync=false) const |
int | Create (unsigned long &ThreadId, Handle *const &H=0, const bool &CreateDetached=false, const unsigned int &StackSize=0, const bool &CancelEnable=false, const bool &CancelAsync=false) const |
int | Create (unsigned long &ThreadId, Handle *const &H=0, const bool &CreateDetached=false, const unsigned int &StackSize=0, const bool &CancelEnable=false, const bool &CancelAsync=false) const |
virtual | ~UThreadC () |
virtual | ~UThreadC () |
Public Member Functions inherited from UEventsSender | |
UEventsSender () | |
virtual | ~UEventsSender () |
Static Public Member Functions | |
static LaserScan | scanFromPointCloudData (const cv::Mat &pointCloudData, int points, const Transform &pose, const CameraModel &model, const cv::Mat &rgb, std::vector< cv::KeyPoint > *kpts=0, std::vector< cv::Point3f > *kpts3D=0, int kptsSize=3) |
Static Public Member Functions inherited from UThread | |
static unsigned long | currentThreadId () |
Static Public Member Functions inherited from UThreadC< void > | |
static int | Create (const Handler &Function, Handle *const &H=0, const bool &CreateDetached=false, const unsigned int &StackSize=0, const bool &CancelEnable=false, const bool &CancelAsync=false) |
static int | Create (const Handler &Function, Handle *const &H=0, const bool &CreateDetached=false, const unsigned int &StackSize=0, const bool &CancelEnable=false, const bool &CancelAsync=false) |
static int | Detach (Handle H) |
static int | Detach (const Handle &H) |
static int | Join (const Handle &H) |
static int | Join (Handle H) |
static int | Kill (Handle H) |
static int | Kill (const Handle &H) |
Static Public Attributes | |
static const float | bilateralFilteringSigmaR = 0.075f |
static const float | bilateralFilteringSigmaS = 2.0f |
static const rtabmap::Transform | opticalRotation |
static const rtabmap::Transform | opticalRotationInv |
Protected Member Functions | |
virtual SensorData | captureImage (CameraInfo *info=0) |
virtual void | capturePoseOnly () |
virtual void | mainLoop () |
virtual void | mainLoopBegin () |
Protected Member Functions inherited from rtabmap::Camera | |
Camera (float imageRate=0, const Transform &localTransform=Transform::getIdentity()) | |
int | getNextSeqID () |
Protected Member Functions inherited from UThreadC< void > | |
UThreadC () | |
UThreadC () | |
Protected Member Functions inherited from UEventsSender | |
void | post (UEvent *event, bool async=true) const |
Protected Attributes | |
Transform | deviceTColorCamera_ |
CameraModel | model_ |
glm::mat4 | projectionMatrix_ |
UTimer | spinOnceFrameRateTimer_ |
double | spinOncePreviousStamp_ |
GLuint | textureId_ |
float | transformed_uvs_ [8] |
bool | uvs_initialized_ = false |
glm::mat4 | viewMatrix_ |
Private Attributes | |
UTimer | cameraStartedTime_ |
ScreenRotation | colorCameraToDisplayRotation_ |
SensorData | data_ |
EnvSensors | lastEnvSensors_ |
GPS | lastKnownGPS_ |
cv::Mat | occlusionImage_ |
CameraModel | occlusionModel_ |
Transform | originOffset_ |
bool | originUpdate_ |
Transform | pose_ |
Transform | previousPose_ |
double | previousStamp_ |
bool | smoothing_ |
double | stampEpochOffset_ |
Additional Inherited Members | |
Public Types inherited from UThread | |
enum | Priority { kPLow, kPBelowNormal, kPNormal, kPAboveNormal, kPRealTime } |
Public Types inherited from UThreadC< void > | |
typedef THREAD_HANDLE | Handle |
typedef THREAD_HANDLE | Handle |
typedef void(* | Handler) () |
typedef void(* | Handler) () |
Static Protected Member Functions inherited from UThreadC< void > | |
static void | Exit () |
static void | Exit () |
static Handle | Self () |
static int | Self () |
static void | TestCancel () |
static void | TestCancel () |
Definition at line 71 of file CameraMobile.h.
rtabmap::CameraMobile::CameraMobile | ( | bool | smoothing = false | ) |
Definition at line 55 of file CameraMobile.cpp.
|
virtual |
Definition at line 69 of file CameraMobile.cpp.
void rtabmap::CameraMobile::addEnvSensor | ( | int | type, |
float | value | ||
) |
Definition at line 198 of file CameraMobile.cpp.
|
protectedvirtual |
returned rgb and depth images should be already rectified if calibration was loaded
Implements rtabmap::Camera.
Reimplemented in rtabmap::CameraARCore, rtabmap::CameraTango, and rtabmap::CameraAREngine.
Definition at line 396 of file CameraMobile.cpp.
|
inlineprotectedvirtual |
Reimplemented in rtabmap::CameraARCore, and rtabmap::CameraAREngine.
Definition at line 126 of file CameraMobile.h.
|
virtual |
Reimplemented in rtabmap::CameraARCore, rtabmap::CameraAREngine, and rtabmap::CameraTango.
Definition at line 80 of file CameraMobile.cpp.
|
inline |
Definition at line 105 of file CameraMobile.h.
|
inline |
Definition at line 106 of file CameraMobile.h.
|
inline |
Definition at line 122 of file CameraMobile.h.
|
inline |
Definition at line 99 of file CameraMobile.h.
|
inline |
Definition at line 119 of file CameraMobile.h.
|
inlinevirtual |
Implements rtabmap::Camera.
Reimplemented in rtabmap::CameraARCore, rtabmap::CameraAREngine, and rtabmap::CameraTango.
Definition at line 97 of file CameraMobile.h.
|
inline |
Definition at line 115 of file CameraMobile.h.
Definition at line 118 of file CameraMobile.h.
|
virtual |
Implements rtabmap::Camera.
Reimplemented in rtabmap::CameraARCore, rtabmap::CameraAREngine, and rtabmap::CameraTango.
Definition at line 74 of file CameraMobile.cpp.
|
virtual |
Implements rtabmap::Camera.
Definition at line 132 of file CameraMobile.cpp.
|
protectedvirtual |
Pure virtual method mainLoop(). The inner loop of the thread. This method is called repetitively until the thread is killed. Note that if kill() is called in mainLoopBegin(), mainLoop() is not called, terminating immediately the thread.
Implements UThread.
Definition at line 242 of file CameraMobile.cpp.
|
protectedvirtual |
Virtual method mainLoopBegin(). User can implement this function to add a behavior before the main loop is started. It is called once (before entering mainLoop()).
Reimplemented from UThread.
Definition at line 233 of file CameraMobile.cpp.
void rtabmap::CameraMobile::poseReceived | ( | const Transform & | pose | ) |
Definition at line 109 of file CameraMobile.cpp.
void rtabmap::CameraMobile::resetOrigin | ( | ) |
Definition at line 98 of file CameraMobile.cpp.
|
static |
Definition at line 405 of file CameraMobile.cpp.
void rtabmap::CameraMobile::setData | ( | const SensorData & | data, |
const Transform & | pose, | ||
const glm::mat4 & | viewMatrix, | ||
const glm::mat4 & | projectionMatrix, | ||
const float * | texCoord | ||
) |
Definition at line 142 of file CameraMobile.cpp.
void rtabmap::CameraMobile::setGPS | ( | const GPS & | gps | ) |
Definition at line 137 of file CameraMobile.cpp.
|
inline |
Definition at line 121 of file CameraMobile.h.
|
inlinevirtual |
Reimplemented in rtabmap::CameraARCore.
Definition at line 108 of file CameraMobile.h.
|
inline |
Definition at line 107 of file CameraMobile.h.
void rtabmap::CameraMobile::spinOnce | ( | ) |
Definition at line 203 of file CameraMobile.cpp.
|
inline |
Definition at line 116 of file CameraMobile.h.
|
inline |
Definition at line 117 of file CameraMobile.h.
|
static |
Definition at line 74 of file CameraMobile.h.
|
static |
Definition at line 73 of file CameraMobile.h.
|
private |
Definition at line 146 of file CameraMobile.h.
|
private |
Definition at line 149 of file CameraMobile.h.
|
private |
Definition at line 155 of file CameraMobile.h.
|
protected |
Definition at line 133 of file CameraMobile.h.
|
private |
Definition at line 151 of file CameraMobile.h.
|
private |
Definition at line 150 of file CameraMobile.h.
|
protected |
Definition at line 132 of file CameraMobile.h.
|
private |
Definition at line 158 of file CameraMobile.h.
|
private |
Definition at line 159 of file CameraMobile.h.
|
static |
Definition at line 76 of file CameraMobile.h.
|
static |
Definition at line 77 of file CameraMobile.h.
|
private |
Definition at line 152 of file CameraMobile.h.
|
private |
Definition at line 153 of file CameraMobile.h.
|
private |
Definition at line 156 of file CameraMobile.h.
|
private |
Definition at line 144 of file CameraMobile.h.
|
private |
Definition at line 145 of file CameraMobile.h.
|
protected |
Definition at line 139 of file CameraMobile.h.
|
private |
Definition at line 148 of file CameraMobile.h.
|
protected |
Definition at line 134 of file CameraMobile.h.
|
protected |
Definition at line 135 of file CameraMobile.h.
|
private |
Definition at line 147 of file CameraMobile.h.
|
protected |
Definition at line 137 of file CameraMobile.h.
|
protected |
Definition at line 140 of file CameraMobile.h.
|
protected |
Definition at line 141 of file CameraMobile.h.
|
protected |
Definition at line 138 of file CameraMobile.h.