avcap::V4L2_FormatManager Class Reference

#include <avcap/linux/V4L2_FormatManager.h>

Inheritance diagram for avcap::V4L2_FormatManager:

Inheritance graph
[legend]

Detailed Description

This class implements the FormatManager for Video4Linux2 devices. */.


Public Member Functions

 V4L2_FormatManager (V4L2_DeviceDescriptor *dd)
virtual ~V4L2_FormatManager ()
int setFormat (Format *fmt)
 Set the format to capture.
int setFormat (unsigned int fourcc)
FormatgetFormat ()
 Get the current format.
int setResolution (int w, int h)
 Set the image with and height.
int setBytesPerLine (int bpl)
 Set the number of used bytes per scanline, if possible.
int getWidth ()
 Returns the image with.
int getHeight ()
 Returns the image height.
int getBytesPerLine ()
 Returns the bytes per line.
int flush ()
 Flushes the format, i.e. the driver is advised to apply the current format settings.
size_t getImageSize ()
 The number of bytes that an image of the current size requires to be stored in memory, including padding.
const VideoStandardgetVideoStandard ()
 Get the currently used video standard.
int setVideoStandard (const VideoStandard *std)
 Set the video standard to use.
int setFramerate (int fps)
 Set the framerate.
int getFramerate ()
 Get the current framerate.
void query ()


Constructor & Destructor Documentation

avcap::V4L2_FormatManager::V4L2_FormatManager ( V4L2_DeviceDescriptor dd  ) 

virtual avcap::V4L2_FormatManager::~V4L2_FormatManager (  )  [virtual]


Member Function Documentation

int avcap::V4L2_FormatManager::setFormat ( Format fmt  )  [virtual]

Set the format to capture.

Parameters:
fmt The new format.
Returns:
0, if successful, -1 else

Reimplemented from avcap::FormatManager.

int avcap::V4L2_FormatManager::setFormat ( unsigned int  fourcc  ) 

Format* avcap::V4L2_FormatManager::getFormat (  )  [virtual]

Get the current format.

Returns:
The format.

Reimplemented from avcap::FormatManager.

int avcap::V4L2_FormatManager::setResolution ( int  w,
int  h 
) [virtual]

Set the image with and height.

Parameters:
w : width
h : height
Returns:
0, if successful, -1 else

Reimplemented from avcap::FormatManager.

int avcap::V4L2_FormatManager::setBytesPerLine ( int  bpl  )  [virtual]

Set the number of used bytes per scanline, if possible.

Parameters:
bpl 
Returns:
0, if successful, -1 else

Reimplemented from avcap::FormatManager.

int avcap::V4L2_FormatManager::getWidth (  )  [virtual]

Returns the image with.

Returns:
width

Reimplemented from avcap::FormatManager.

int avcap::V4L2_FormatManager::getHeight (  )  [virtual]

Returns the image height.

Returns:
height

Reimplemented from avcap::FormatManager.

int avcap::V4L2_FormatManager::getBytesPerLine (  )  [virtual]

Returns the bytes per line.

Returns:
bpl

Reimplemented from avcap::FormatManager.

int avcap::V4L2_FormatManager::flush (  )  [virtual]

Flushes the format, i.e. the driver is advised to apply the current format settings.

Returns:
0, if successful, -1 else

Reimplemented from avcap::FormatManager.

size_t avcap::V4L2_FormatManager::getImageSize (  )  [virtual]

The number of bytes that an image of the current size requires to be stored in memory, including padding.

Returns:
size

Reimplemented from avcap::FormatManager.

const VideoStandard* avcap::V4L2_FormatManager::getVideoStandard (  )  [virtual]

Get the currently used video standard.

The default implementation returns 0

Returns:
the current standard or 0, if not applicable

Reimplemented from avcap::FormatManager.

int avcap::V4L2_FormatManager::setVideoStandard ( const VideoStandard std  )  [virtual]

Set the video standard to use.

Attention: not all video standards can be set in conjunction with each connector and format. The default implementation returns -1

Parameters:
std The new video standard.
Returns:
0, if successful, -1 else

Reimplemented from avcap::FormatManager.

int avcap::V4L2_FormatManager::setFramerate ( int  fps  )  [virtual]

Set the framerate.

The default implementation returns -1

Parameters:
fps : the number of frames per second.
Returns:
0 if successful, -1 on failure

Reimplemented from avcap::FormatManager.

int avcap::V4L2_FormatManager::getFramerate (  )  [virtual]

Get the current framerate.

The default implementation returns -1 /*!

Returns:
the frames per second

Reimplemented from avcap::FormatManager.

void avcap::V4L2_FormatManager::query (  )  [virtual]

Called during initialisation by the CaptureDevice to query for the objects that the implementation of this class manages.

Implements avcap::FormatManager.


The documentation for this class was generated from the following file:
Generated on Mon Nov 30 11:10:33 2009 for avcap-0.1 by  doxygen 1.5.1