Public Member Functions | Protected Member Functions | Private Attributes
rtabmap::CompressionThread Class Reference

#include <Compression.h>

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

List of all members.

Public Member Functions

 CompressionThread (const cv::Mat &mat, const std::string &format="")
 CompressionThread (const cv::Mat &bytes, bool isImage)
const cv::Mat & getCompressedData () const
cv::Mat & getUncompressedData ()

Protected Member Functions

virtual void mainLoop ()

Private Attributes

cv::Mat compressedData_
bool compressMode_
std::string format_
bool image_
cv::Mat uncompressedData_

Detailed Description

Compress image or data

Example compression: cv::Mat image;// an image CompressionThread ct(image); ct.start(); ct.join(); std::vector<unsigned char> bytes = ct.getCompressedData();

Example uncompression std::vector<unsigned char> bytes;// a compressed image CompressionThread ct(bytes); ct.start(); ct.join(); cv::Mat image = ct.getUncompressedData();

Definition at line 55 of file Compression.h.


Constructor & Destructor Documentation

rtabmap::CompressionThread::CompressionThread ( const cv::Mat &  mat,
const std::string &  format = "" 
)

Definition at line 38 of file Compression.cpp.

rtabmap::CompressionThread::CompressionThread ( const cv::Mat &  bytes,
bool  isImage 
)

Definition at line 47 of file Compression.cpp.


Member Function Documentation

const cv::Mat& rtabmap::CompressionThread::getCompressedData ( ) const [inline]

Definition at line 61 of file Compression.h.

Definition at line 62 of file Compression.h.

void rtabmap::CompressionThread::mainLoop ( ) [protected, virtual]

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.

See also:
mainLoop()
kill()

Implements UThread.

Definition at line 52 of file Compression.cpp.


Member Data Documentation

Definition at line 66 of file Compression.h.

Definition at line 70 of file Compression.h.

std::string rtabmap::CompressionThread::format_ [private]

Definition at line 68 of file Compression.h.

Definition at line 69 of file Compression.h.

Definition at line 67 of file Compression.h.


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


rtabmap
Author(s): Mathieu Labbe
autogenerated on Fri Aug 28 2015 12:51:43