Public Types | Public Member Functions | Protected Member Functions | Private Attributes | List of all members
rtabmap::CameraVideo Class Reference

#include <CameraVideo.h>

Inheritance diagram for rtabmap::CameraVideo:
Inheritance graph
[legend]

Public Types

enum  Source { kVideoFile, kUsbDevice }
 

Public Member Functions

 CameraVideo (const std::string &filePath, bool rectifyImages=false, float imageRate=0, const Transform &localTransform=Transform::getIdentity())
 
 CameraVideo (int usbDevice=0, bool rectifyImages=false, float imageRate=0, const Transform &localTransform=Transform::getIdentity())
 
const std::stringgetFilePath () const
 
virtual std::string getSerial () const
 
int getUsbDevice () const
 
virtual bool init (const std::string &calibrationFolder=".", const std::string &cameraName="")
 
virtual bool isCalibrated () const
 
void setResolution (int width, int height)
 
virtual ~CameraVideo ()
 
- Public Member Functions inherited from rtabmap::Camera
float getImageRate () const
 
bool initFromFile (const std::string &calibrationPath)
 
bool isInterIMUPublishing () const
 
void setImageRate (float imageRate)
 
void setInterIMUPublishing (bool enabled, IMUFilter *filter=0)
 
SensorData takeImage (SensorCaptureInfo *info=0)
 
virtual ~Camera ()
 
- Public Member Functions inherited from rtabmap::SensorCapture
float getFrameRate () const
 
const TransformgetLocalTransform () const
 
virtual bool getPose (double stamp, Transform &pose, cv::Mat &covariance, double maxWaitTime=0.06)
 
virtual bool odomProvided () const
 
void resetTimer ()
 
void setFrameRate (float frameRate)
 
void setLocalTransform (const Transform &localTransform)
 
SensorData takeData (SensorCaptureInfo *info=0)
 
virtual ~SensorCapture ()
 

Protected Member Functions

virtual SensorData captureImage (SensorCaptureInfo *info=0)
 
- Protected Member Functions inherited from rtabmap::Camera
 Camera (float imageRate=0, const Transform &localTransform=Transform::getIdentity())
 
void postInterIMU (const IMU &imu, double stamp)
 
- Protected Member Functions inherited from rtabmap::SensorCapture
int getNextSeqID ()
 
 SensorCapture (float frameRate=0, const Transform &localTransform=Transform::getIdentity())
 

Private Attributes

cv::VideoCapture _capture
 
std::string _filePath
 
std::string _guid
 
int _height
 
CameraModel _model
 
bool _rectifyImages
 
Source _src
 
int _usbDevice
 
int _width
 

Detailed Description

Definition at line 36 of file CameraVideo.h.

Member Enumeration Documentation

◆ Source

Enumerator
kVideoFile 
kUsbDevice 

Definition at line 40 of file CameraVideo.h.

Constructor & Destructor Documentation

◆ CameraVideo() [1/2]

rtabmap::CameraVideo::CameraVideo ( int  usbDevice = 0,
bool  rectifyImages = false,
float  imageRate = 0,
const Transform localTransform = Transform::getIdentity() 
)

Definition at line 41 of file CameraVideo.cpp.

◆ CameraVideo() [2/2]

rtabmap::CameraVideo::CameraVideo ( const std::string filePath,
bool  rectifyImages = false,
float  imageRate = 0,
const Transform localTransform = Transform::getIdentity() 
)

Definition at line 56 of file CameraVideo.cpp.

◆ ~CameraVideo()

rtabmap::CameraVideo::~CameraVideo ( )
virtual

Definition at line 71 of file CameraVideo.cpp.

Member Function Documentation

◆ captureImage()

SensorData rtabmap::CameraVideo::captureImage ( SensorCaptureInfo info = 0)
protectedvirtual

Implements rtabmap::Camera.

Definition at line 165 of file CameraVideo.cpp.

◆ getFilePath()

const std::string& rtabmap::CameraVideo::getFilePath ( ) const
inline

Definition at line 57 of file CameraVideo.h.

◆ getSerial()

std::string rtabmap::CameraVideo::getSerial ( ) const
virtual

Implements rtabmap::SensorCapture.

Definition at line 160 of file CameraVideo.cpp.

◆ getUsbDevice()

int rtabmap::CameraVideo::getUsbDevice ( ) const
inline

Definition at line 56 of file CameraVideo.h.

◆ init()

bool rtabmap::CameraVideo::init ( const std::string calibrationFolder = ".",
const std::string cameraName = "" 
)
virtual

Implements rtabmap::SensorCapture.

Definition at line 76 of file CameraVideo.cpp.

◆ isCalibrated()

bool rtabmap::CameraVideo::isCalibrated ( ) const
virtual

Implements rtabmap::Camera.

Definition at line 155 of file CameraVideo.cpp.

◆ setResolution()

void rtabmap::CameraVideo::setResolution ( int  width,
int  height 
)
inline

Set wanted usb resolution, should be set before initialization. 0 means default resolution. It won't be applied if a valid camera calibration has been loaded, thus resolution from calibration is used.

Definition at line 64 of file CameraVideo.h.

Member Data Documentation

◆ _capture

cv::VideoCapture rtabmap::CameraVideo::_capture
private

Definition at line 74 of file CameraVideo.h.

◆ _filePath

std::string rtabmap::CameraVideo::_filePath
private

Definition at line 71 of file CameraVideo.h.

◆ _guid

std::string rtabmap::CameraVideo::_guid
private

Definition at line 79 of file CameraVideo.h.

◆ _height

int rtabmap::CameraVideo::_height
private

Definition at line 81 of file CameraVideo.h.

◆ _model

CameraModel rtabmap::CameraVideo::_model
private

Definition at line 83 of file CameraVideo.h.

◆ _rectifyImages

bool rtabmap::CameraVideo::_rectifyImages
private

Definition at line 72 of file CameraVideo.h.

◆ _src

Source rtabmap::CameraVideo::_src
private

Definition at line 75 of file CameraVideo.h.

◆ _usbDevice

int rtabmap::CameraVideo::_usbDevice
private

Definition at line 78 of file CameraVideo.h.

◆ _width

int rtabmap::CameraVideo::_width
private

Definition at line 80 of file CameraVideo.h.


The documentation for this class was generated from the following files:


rtabmap
Author(s): Mathieu Labbe
autogenerated on Thu Jul 25 2024 02:50:27