camera1394_control Class Reference

#include <camera1394_control.h>


Public Member Functions

 camera1394_control ()
 Class constructor.
 ~camera1394_control ()
 Class destructor.
int PrintPossibleModes (void)
 Prints to shell all the camera possible modes.
int PrintPossibleFrameRates (void)
 Prints to shell all the camera possible frame rates.
int PrintCameraFeatures (void)
 Prints to shell all the camera features.
int PrintCameraInfo (void)
 Prints to shell some camera info.
int SetHandleNum (int num)
 Sets the flag HandleNum to num.
int SetNodeNum (int num)
 Sets the flag NodeNum to num.
int SetColorFormat (int cm)
 Sets the camera color format.
int SetFeatureToManualAuto (unsigned int f, unsigned int val)
 Sets a camera feature to manual or auto control.
int SetFlgverbose (unsigned char val)
 Sets the flag verbose to val.
int SetFlgtestimgparams (unsigned char val)
 Sets the flag testimgparams to val.
int DmaUnlisten (void)
int CleanupIsoChannels (void)
int OpenHandle (void)
 Opens the raw1394 handle with the num HandleNum.
int TurnOffCamera (void)
 Turns off the camera in handle handlenum and node nodenum.
int TurnOnCamera (void)
 Turns on the camera in handle handlenum and node nodenum.
int GetCameraNodes (void)
 Gets all the cameras and their nodes in the predefined handlenum.
int SetupCapture_dma (void)
 Sets up the capture.
int StartIsoTransmission (void)
 Starts iso transmission.
int GetFrame_dma (IplImage *img)
 Gets an image from the camera at handle handlenum and node nodenum.
int InitCameraToFactorySettings (void)
 Inits camera to its factory settings.
int GetFrameRate (void)
int GetBrightness (void)
int GetSaturation (void)
int GetExposure (void)
int GetSharpness (void)
int GetWhiteBalance (void)
int GetHue (void)
int GetGamma (void)
int GetShutter (void)
int GetGain (void)
int SetFrameRate (int fr)
int SetBrightness (unsigned int b)
int SetSaturation (unsigned int s)
int SetExposure (unsigned int e)
int SetSharpness (unsigned int s)
int SetWhiteBalance (unsigned int ub, unsigned int vr)
int SetHue (unsigned int h)
int SetGamma (unsigned int g)
int SetShutter (unsigned int s)
int SetGain (unsigned int g)

Private Attributes

raw1394handle_t handle
int handlenum
int nodenum
nodeid_t * numnodes
dc1394_feature_info * feature
dc1394_feature_set * featureset
dc1394_miscinfo * info
dc1394_camerainfo * camerainfo
int numCameras
dc1394_cameracapture cameracapture
char * devicename
unsigned char * TmpBuffer
struct {
   unsigned char   verbose
   unsigned char   hashandle
   unsigned char   testimgparams
flg
struct {
   int   width
   int   height
   int   numchannels
   int   colormode
   int   framerate
   unsigned int   Brightness
   unsigned int   Exposure
   unsigned int   Sharpness
   unsigned int   Hue
   unsigned int   Saturation
   unsigned int   Gamma
   unsigned int   Temperature
   unsigned int   Shutter
   unsigned int   Gain
   unsigned int   FrameRate
   struct {
      unsigned int   u_b_value
      unsigned int   v_r_value
   }   WhiteBalance
captureparams


Constructor & Destructor Documentation

camera1394_control::camera1394_control (  ) 

Class constructor.

camera1394_control::~camera1394_control (  ) 

Class destructor.


Member Function Documentation

int camera1394_control::CleanupIsoChannels ( void   )  [inline]

int camera1394_control::DmaUnlisten ( void   )  [inline]

int camera1394_control::GetBrightness ( void   ) 

int camera1394_control::GetCameraNodes ( void   ) 

Gets all the cameras and their nodes in the predefined handlenum.

Returns:
function result. 1 is OK 0 is NOK

int camera1394_control::GetExposure ( void   ) 

int camera1394_control::GetFrame_dma ( IplImage *  img  ) 

Gets an image from the camera at handle handlenum and node nodenum.

The img data will be filled with the captured frame information. If testimgparams flag is set (it's set by default) the function first checks if the img properties are the same as the capture ones avoiding a runtime crash. Of course this test will take a bit longer if performed.

Parameters:
img Pointer to the user image.
Returns:
function result. 1 is OK 0 is NOK

int camera1394_control::GetFrameRate ( void   ) 

int camera1394_control::GetGain ( void   ) 

int camera1394_control::GetGamma ( void   ) 

int camera1394_control::GetHue ( void   ) 

int camera1394_control::GetSaturation ( void   ) 

int camera1394_control::GetSharpness ( void   ) 

int camera1394_control::GetShutter ( void   ) 

int camera1394_control::GetWhiteBalance ( void   ) 

int camera1394_control::InitCameraToFactorySettings ( void   )  [inline]

Inits camera to its factory settings.

Returns:
function result. 1 is OK 0 is NOK

int camera1394_control::OpenHandle ( void   ) 

Opens the raw1394 handle with the num HandleNum.

Returns:
function result. 1 is OK 0 is NOK

int camera1394_control::PrintCameraFeatures ( void   )  [inline]

Prints to shell all the camera features.

Returns:
function result. 1 is OK 0 is NOK

int camera1394_control::PrintCameraInfo ( void   )  [inline]

Prints to shell some camera info.

Returns:
function result. 1 is OK 0 is NOK

int camera1394_control::PrintPossibleFrameRates ( void   ) 

Prints to shell all the camera possible frame rates.

Returns:
function result. 1 is OK 0 is NOK

int camera1394_control::PrintPossibleModes ( void   ) 

Prints to shell all the camera possible modes.

Returns:
function result. 1 is OK 0 is NOK

int camera1394_control::SetBrightness ( unsigned int  b  ) 

int camera1394_control::SetColorFormat ( int  cm  ) 

Sets the camera color format.

The color format is defined in an enum declared in dc1394_control.h
The supported modes are:

If none of this modes is selected the default mode MODE_320x240_YUV422 is selected

Parameters:
cm Color format reference given by an enum defined in dc1394_control.h
Returns:
function result. 1 is OK 0 is NOK

int camera1394_control::SetExposure ( unsigned int  e  ) 

int camera1394_control::SetFeatureToManualAuto ( unsigned int  f,
unsigned int  val 
)

Sets a camera feature to manual or auto control.

The available features are defined in a enum of dc1394_control.h
These are:

int camera1394_control::SetFlgtestimgparams ( unsigned char  val  )  [inline]

Sets the flag testimgparams to val.

If true every time a get image is called the pointer to the image is first tested avoiding a runtime crash.

Parameters:
val 1 for TRUE or 0 for FALSE
Returns:
function result. 1 is OK 0 is NOK

int camera1394_control::SetFlgverbose ( unsigned char  val  )  [inline]

Sets the flag verbose to val.

If true reports will be written to the shell.

Parameters:
val 1 for TRUE or 0 for FALSE
Returns:
function result. 1 is OK 0 is NOK

int camera1394_control::SetFrameRate ( int  fr  ) 

int camera1394_control::SetGain ( unsigned int  g  ) 

int camera1394_control::SetGamma ( unsigned int  g  ) 

int camera1394_control::SetHandleNum ( int  num  )  [inline]

Sets the flag HandleNum to num.

Parameters:
num Number of the handle
Returns:
function result. 1 is OK 0 is NOK

int camera1394_control::SetHue ( unsigned int  h  ) 

int camera1394_control::SetNodeNum ( int  num  )  [inline]

Sets the flag NodeNum to num.

Parameters:
num Number of the node
Returns:
function result. 1 is OK 0 is NOK

int camera1394_control::SetSaturation ( unsigned int  s  ) 

int camera1394_control::SetSharpness ( unsigned int  s  ) 

int camera1394_control::SetShutter ( unsigned int  s  ) 

int camera1394_control::SetupCapture_dma ( void   ) 

Sets up the capture.

Returns:
function result. 1 is OK 0 is NOK

int camera1394_control::SetWhiteBalance ( unsigned int  ub,
unsigned int  vr 
)

int camera1394_control::StartIsoTransmission ( void   ) 

Starts iso transmission.

Returns:
function result. 1 is OK 0 is NOK

int camera1394_control::TurnOffCamera ( void   ) 

Turns off the camera in handle handlenum and node nodenum.

Returns:
function result. 1 is OK 0 is NOK

int camera1394_control::TurnOnCamera ( void   ) 

Turns on the camera in handle handlenum and node nodenum.

Returns:
function result. 1 is OK 0 is NOK


Field Documentation

unsigned int camera1394_control::Brightness [private]

dc1394_cameracapture camera1394_control::cameracapture [private]

dc1394_camerainfo* camera1394_control::camerainfo [private]

struct { ... } camera1394_control::captureparams [private]

int camera1394_control::colormode [private]

char* camera1394_control::devicename [private]

unsigned int camera1394_control::Exposure [private]

dc1394_feature_info* camera1394_control::feature [private]

dc1394_feature_set* camera1394_control::featureset [private]

struct { ... } camera1394_control::flg [private]

unsigned int camera1394_control::FrameRate [private]

int camera1394_control::framerate [private]

unsigned int camera1394_control::Gain [private]

unsigned int camera1394_control::Gamma [private]

raw1394handle_t camera1394_control::handle [private]

int camera1394_control::handlenum [private]

unsigned char camera1394_control::hashandle [private]

int camera1394_control::height [private]

unsigned int camera1394_control::Hue [private]

dc1394_miscinfo* camera1394_control::info [private]

int camera1394_control::nodenum [private]

int camera1394_control::numCameras [private]

int camera1394_control::numchannels [private]

nodeid_t* camera1394_control::numnodes [private]

unsigned int camera1394_control::Saturation [private]

unsigned int camera1394_control::Sharpness [private]

unsigned int camera1394_control::Shutter [private]

unsigned int camera1394_control::Temperature [private]

unsigned char camera1394_control::testimgparams [private]

unsigned char* camera1394_control::TmpBuffer [private]

unsigned int camera1394_control::u_b_value [private]

unsigned int camera1394_control::v_r_value [private]

unsigned char camera1394_control::verbose [private]

struct { ... } camera1394_control::WhiteBalance [private]

int camera1394_control::width [private]


The documentation for this class was generated from the following files:
Generated on Tue Jan 30 15:33:07 2007 for camera1394_control.kdevelop by  doxygen 1.4.7