AURobotServers  4
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
CCameraOutput Class Reference

#include <camera.h>

Public Member Functions

bool BeginReadFrame (const void *&out_buffer, int &out_buffer_size)
 
MMAL_BUFFER_HEADER_T * BeginReadFrame ()
 
 CCameraOutput ()
 
MMAL_COMPONENT_T * CreateResizeComponentAndSetupPorts (MMAL_PORT_T *video_output_port, bool do_argb_conversion)
 
MMAL_POOL_T * EnablePortCallbackAndCreateBufferPool (MMAL_PORT_T *port, MMAL_PORT_BH_CB_T cb, int buffer_count)
 
void EndReadFrame ()
 
bool Init (int width, int height, MMAL_COMPONENT_T *input_component, int input_port_idx, bool do_argb_conversion, USemaphore *postOnNewImage)
 
void OnVideoBufferCallback (MMAL_PORT_T *port, MMAL_BUFFER_HEADER_T *buffer)
 
int ReadFrame (void *buffer, int buffer_size)
 
void Release ()
 
 ~CCameraOutput ()
 

Static Public Member Functions

static void VideoBufferCallback (MMAL_PORT_T *port, MMAL_BUFFER_HEADER_T *buffer)
 

Public Attributes

MMAL_POOL_T * BufferPool
 
MMAL_PORT_T * BufferPort
 
MMAL_CONNECTION_T * Connection
 
int Height
 
MMAL_BUFFER_HEADER_T * LockedBuffer
 
USemaphorenewImg
 
MMAL_QUEUE_T * OutputQueue
 
MMAL_COMPONENT_T * ResizerComponent
 
int Width
 

Constructor & Destructor Documentation

CCameraOutput::CCameraOutput ( )
CCameraOutput::~CCameraOutput ( )

Member Function Documentation

bool CCameraOutput::BeginReadFrame ( const void *&  out_buffer,
int &  out_buffer_size 
)

Referenced by CCamera::BeginReadFrame().

MMAL_BUFFER_HEADER_T * CCameraOutput::BeginReadFrame ( )

begin read frame - gets buffer element and locks it

Returns
pointer to a locked buffer or NULL if no buffer is available
MMAL_COMPONENT_T * CCameraOutput::CreateResizeComponentAndSetupPorts ( MMAL_PORT_T *  video_output_port,
bool  do_argb_conversion 
)

References CCamera::Height, and CCamera::Width.

MMAL_POOL_T * CCameraOutput::EnablePortCallbackAndCreateBufferPool ( MMAL_PORT_T *  port,
MMAL_PORT_BH_CB_T  cb,
int  buffer_count 
)
void CCameraOutput::EndReadFrame ( )

Referenced by CCamera::EndReadFrame().

bool CCameraOutput::Init ( int  width,
int  height,
MMAL_COMPONENT_T *  input_component,
int  input_port_idx,
bool  do_argb_conversion,
USemaphore postOnNewImage 
)

References CCamera::Height, and CCamera::Width.

void CCameraOutput::OnVideoBufferCallback ( MMAL_PORT_T *  port,
MMAL_BUFFER_HEADER_T *  buffer 
)
int CCameraOutput::ReadFrame ( void *  buffer,
int  buffer_size 
)
void CCameraOutput::Release ( )

Referenced by CCamera::Init(), and CCamera::Release().

void CCameraOutput::VideoBufferCallback ( MMAL_PORT_T *  port,
MMAL_BUFFER_HEADER_T *  buffer 
)
static

Member Data Documentation

MMAL_POOL_T* CCameraOutput::BufferPool
MMAL_PORT_T* CCameraOutput::BufferPort
MMAL_CONNECTION_T* CCameraOutput::Connection
int CCameraOutput::Height
MMAL_BUFFER_HEADER_T* CCameraOutput::LockedBuffer
USemaphore* CCameraOutput::newImg
MMAL_QUEUE_T* CCameraOutput::OutputQueue
MMAL_COMPONENT_T* CCameraOutput::ResizerComponent
int CCameraOutput::Width

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