MarsSDK
Public Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
ColorStream Class Reference

Color image stream from the camera. More...

#include <MarsSDK.h>

Inheritance diagram for ColorStream:
Stream

Public Member Functions

 ~ColorStream ()
 Destructor to delete memory allocation for instance of ColorStream.
 
int update ()
 Updates the stream's contents from the camera. More...
 
short * getFrame ()
 Returns the color data. Uses the frame from the latest call to ColorStream::update(). More...
 
- Public Member Functions inherited from Stream
int getWidth ()
 Returns the Stream's width, in pixels. More...
 
int getHeight ()
 Returns the Stream's height, in pixels. More...
 
int getSize ()
 Returns the Stream's size, in pixels. More...
 

Private Member Functions

 ColorStream (CLibTof *_camera)
 Constructor to create a new instance of ColorStream. More...
 

Private Attributes

short * frame
 Color frame buffer In YUV420 format.
 

Friends

class Mars
 

Additional Inherited Members

- Protected Attributes inherited from Stream
CLibTof * camera
 Instance of camera in external Sunny Mars API.
 
int width
 Stream's width, in pixels.
 
int height
 Stream's height, in pixels.
 
int size
 Stream's size, in pixels.
 

Detailed Description

Color image stream from the camera.

Constructor & Destructor Documentation

◆ ColorStream()

ColorStream ColorStream::ColorStream ( CLibTof *  _camera)
private

Constructor to create a new instance of ColorStream.

Parameters
[in]_cameraInstance of camera.

Member Function Documentation

◆ getFrame()

short * ColorStream::getFrame ( )

Returns the color data. Uses the frame from the latest call to ColorStream::update().

Returns
frame

◆ update()

int ColorStream::update ( )

Updates the stream's contents from the camera.

Returns
Error code

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