AURobotServers  4
Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes | Protected Attributes | Static Protected Attributes | List of all members
UCamDevBase Class Reference

#include <ucamdevbase.h>

Inheritance diagram for UCamDevBase:
Inheritance graph

Public Types

enum  camTypes {
  CAM_DEV_REPLAY, CAM_DEV_PWC, CAM_DEV_IEEE1394, CAM_DEV_GRAPPER,
  CAM_DEV_GIGE
}
 
typedef enum UCamDevBase::camTypes USupportedCamTypes
 

Public Member Functions

virtual void callGotNewDataWithObject ()
 
virtual void closeDevice ()
 
virtual void createVars ()
 
virtual bool deviceExist ()
 
virtual int getBrightness (bool)
 
char * getCameraName ()
 
int getCamFd ()
 
virtual int getColour (bool)
 
virtual int getCompPref (bool)
 
virtual int getContour (bool)
 
virtual int getContrast (bool)
 
virtual int getDataChannel ()
 
virtual const char * getDataChannelName ()
 
int getDeviceNumber ()
 
virtual bool getExternalTrigger (bool *supported)
 
virtual int getFrameRate ()
 
virtual int getGain (bool, bool *, bool *)
 
virtual int getGamma (bool)
 
unsigned int getHeight ()
 
unsigned long getImageNumber ()
 
virtual bool getImageSnapshot (UImage *image)
 
bool getLockedNewImage (UImage **raw)
 
char * getName ()
 
double getPixelSize ()
 
virtual int getShutter (bool, bool *, bool *)
 
int getWBModeFromString (const char *mode)
 
virtual bool getWhiteBalance (bool, int *, int *, int *)
 
unsigned int getWidth ()
 
void gotNewImage (UImage *rgb)
 
void imageSizeChanged (double iResFactor)
 
void imgUpdated ()
 
bool isCameraOpen ()
 
bool isLog ()
 
bool isReplay ()
 
virtual bool isThisA (USupportedCamTypes thisType)
 
virtual bool makeTriggerPulse ()
 
bool needNewPushData ()
 
virtual bool openDevice ()
 
virtual bool openDeviceDefault ()
 
virtual bool setBrightness (int brightness)
 
void setCam (UCamBase *camRef)
 
virtual bool setColour (int colour)
 
virtual bool setCompPref (int value)
 
virtual bool setContour (int value=0x1000)
 
virtual bool setContrast (int contrast)
 
virtual bool setDataChannel (int)
 
virtual bool setDevice (const int width, const int height, const int framesPerSec)
 
void setDeviceNumber (int deviceNum)
 
virtual bool setExternalTrigger (bool, bool *supported)
 
virtual bool setGain (int)
 
virtual bool setGamma (int gamma)
 
void setImageNumber (unsigned long serial)
 
void setInitialized (bool value)
 
void setLog (bool value)
 
virtual void setPushBuffer (UImage *)
 
void setReplay (bool value)
 
virtual bool setShutter (int)
 
void setTypeName (const char *newName)
 
void setVarPool (UVarPool *vpd)
 
virtual bool setVideoCap (int, int, int, int)
 
virtual bool setWhiteBalance (int, int, int)
 
 UCamDevBase ()
 
virtual ~UCamDevBase ()
 
- Public Member Functions inherited from ULock
bool lock ()
 
void lockInit ()
 
void post ()
 
bool tryLock ()
 
bool tryWait ()
 
 ULock ()
 
void unlock ()
 
bool wait ()
 
 ~ULock ()
 

Static Public Member Functions

static char * getWBModeAsString (int mode, char *strBuff)
 

Static Public Attributes

static const int MAX_CAM_DEV_NAME_LENGTH = 100
 
static const int MAX_IMAGE_WIDTH = 640
 

Protected Attributes

UCamBasecam
 
int cam_fd
 
bool cameraOpen
 
char camName [MAX_CAM_DEV_NAME_LENGTH]
 
USupportedCamTypes camType
 
int devNum
 file descriptor for camera device More...
 
int frameHeight
 
int frameRate
 
int frameWidth
 
unsigned long imageNumber
 
int imCnt
 
UImageimgBuff [RAW_IMAGEBUFFER_MAX_CNT]
 
int imgBuffNext
 
bool initialized
 
UVariablevarCamName
 camera name from camera More...
 
UVariablevarLog
 Variable for log flag. More...
 
UVariablevarReplay
 Variable for replay. More...
 
UVarPoolvars
 
int vbrightness
 
int vcolour
 
int vcompressionPref
 
int vcontour
 
int vcontrast
 
int vgain
 
int vgamma
 
int vshutter
 

Static Protected Attributes

static const int RAW_IMAGEBUFFER_MAX_CNT = 5
 

Detailed Description

The base class for camera device interface classes

    @author Christian Andersen <jca@oersted.dtu.dk>

Member Typedef Documentation

Basic camera types that are supported.

Member Enumeration Documentation

Basic camera types that are supported.

Enumerator
CAM_DEV_REPLAY 
CAM_DEV_PWC 

FILE is used for a device to load data from a file.

CAM_DEV_IEEE1394 

PWC is a device based on the Philips chipset.

CAM_DEV_GRAPPER 

IEEE1394 is a firewire camera.

CAM_DEV_GIGE 

FRAMEGRAPPER is not a very supported device type.

Constructor & Destructor Documentation

UCamDevBase::UCamDevBase ( )
UCamDevBase::~UCamDevBase ( )
virtual

Destructor

References imgBuff, and RAW_IMAGEBUFFER_MAX_CNT.

Member Function Documentation

virtual void UCamDevBase::callGotNewDataWithObject ( )
inlinevirtual

Called from push structure to get push object and do a call to 'gotNewData(object)'. Should be overwritten by push object holder.

References gotNewImage(), and setLog().

Referenced by UCamPush::callGotNewDataWithObject(), and UCamDevGuppy::~UCamDevGuppy().

virtual void UCamDevBase::closeDevice ( )
inlinevirtual
void UCamDevBase::createVars ( )
virtual

Create locally maintained variables - if any

References UVarPool::addVar(), UVarPool::addVarA(), varCamName, varLog, and vars.

Referenced by setVarPool(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().

virtual bool UCamDevBase::deviceExist ( )
inlinevirtual

Test if souch device exist and can be opened. Returns true if device can be opened (a device exists).

Reimplemented in UCamPwc, and UCamDevGigE.

References getLockedNewImage(), and imageSizeChanged().

Referenced by UCamPool::findDevices(), UCamPool::makeDevice(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().

virtual int UCamDevBase::getBrightness ( bool  )
inlinevirtual

Get brightness in camera - a value of 0xFFFF probably means 'not supported'. These values are probed together: Contrast, brightness, colour and gamma, so probe for one of them only.

Reimplemented in UCamPwc.

References vbrightness.

Referenced by UComCam::setFromCam().

char* UCamDevBase::getCameraName ( )
inline
int UCamDevBase::getCamFd ( )
inline
virtual int UCamDevBase::getColour ( bool  )
inlinevirtual

Get colour saturation in camera - a value of 0xFFFF probably means 'not supported'. These values are probed together: Contrast, brightness, colour and gamma, so probe for one of them only.

Reimplemented in UCamPwc.

References vcolour.

Referenced by UComCam::setFromCam().

virtual int UCamDevBase::getCompPref ( bool  )
inlinevirtual

Get current setting of compression preference. 0 = no compression 3 = highest compression. If 'probe' = true the a fresh value is requested from camera, otherwise tha last obtained value is returned. If a requested value is unavailable, then en error is issued.

Reimplemented in UCamPwc.

References vcompressionPref.

Referenced by UComCam::setFromCam().

virtual int UCamDevBase::getContour ( bool  )
inlinevirtual

Get contour value. if 'probe' then a value from camera requested is loaded. if this fails, an error is issued. The function returnes the retreived value (if requested and available) otherwise it returns the last fetched value. NB! if contour is set to automatic the returned value is not related to the implemented value.

Reimplemented in UCamPwc.

References vcontour.

Referenced by UComCam::setFromCam().

virtual int UCamDevBase::getContrast ( bool  )
inlinevirtual

Get contrast in camera - a value of 0xFFFF probably means 'not supported'. This value is probed together with brightness, colour and gamma, so probe for one of these only.

Reimplemented in UCamPwc.

References vcontrast.

Referenced by UComCam::setFromCam().

virtual int UCamDevBase::getDataChannel ( )
inlinevirtual

Get current data channel setting. Returns -1 if channel setting is not supported.

Reimplemented in UCamPwc.

Referenced by UComCam::setFromCam().

virtual const char* UCamDevBase::getDataChannelName ( )
inlinevirtual

Get current data channel name - e.g. Television or s-video on a TV card. Channel is set using setDataChannel().

Reimplemented in UCamPwc.

Referenced by UComCam::setFromCam().

int UCamDevBase::getDeviceNumber ( )
inline
virtual bool UCamDevBase::getExternalTrigger ( bool *  supported)
inlinevirtual

Get external trigger support flag

Parameters
supportedis set true if external trigger is supported by device.
Returns
true if external trigger support call is successful.

Referenced by UCamDevGuppy::~UCamDevGuppy().

virtual int UCamDevBase::getFrameRate ( )
inlinevirtual

Get current frame rate setting

Reimplemented in UCamDevGigE.

References frameRate.

Referenced by UCamPush::print(), UComCam::setFromCam(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().

virtual int UCamDevBase::getGain ( bool  ,
bool *  ,
bool *   
)
inlinevirtual

Get actual gain value. if 'probe' is false, then existing vaue is returned. if 'probe' is true, then the camera is asked for the most recent value. if this is not possible, then en error is reported and last value returned. If dataValid is set, then this is set false on error

Reimplemented in UCamPwc, and UCamDevGigE.

References vgain.

Referenced by UComCam::setFromCam(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().

virtual int UCamDevBase::getGamma ( bool  )
inlinevirtual

Get the current gamma correction value. The value is an integer in 16 bit range, where 0x8000 is default.

Reimplemented in UCamPwc.

References vgamma.

Referenced by UComCam::setFromCam().

unsigned int UCamDevBase::getHeight ( )
inline
unsigned long UCamDevBase::getImageNumber ( )
inline

Get image serial number

References imageNumber.

Referenced by UCalibrate::findGmk(), and UComCam::setFromCam().

bool UCamDevBase::getImageSnapshot ( UImage image)
virtual

Get new image - the newest available. if 'image' == NULL, then get and discard an image.

Returns
true if an image could be captured.

Reimplemented in UCamDevGigE.

References UImage::copy(), getLockedNewImage(), ULock::unlock(), and UImage::valid.

Referenced by UCamRad::getImageSnapshot(), setCam(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().

bool UCamDevBase::getLockedNewImage ( UImage **  raw)

Get the latest new image from the image buffer

lock it so that the user may copy the content if needed, the user will then need to unlock the read buffer after use (or the image buffer is lost for ever, and will drain the tmage read capabilities.

References imCnt, imgBuff, imgBuffNext, isCameraOpen(), openDeviceDefault(), RAW_IMAGEBUFFER_MAX_CNT, UImage::valid, and Wait().

Referenced by deviceExist(), getImageSnapshot(), and testVideo3().

char* UCamDevBase::getName ( )
inline
double UCamDevBase::getPixelSize ( )
inline

Get pixel size relative to 640x480.

Referenced by UCamRad::setCameraParameters(), and UCamRad::updateLensParams().

virtual int UCamDevBase::getShutter ( bool  ,
bool *  ,
bool *   
)
inlinevirtual

Get actual shutter value. if 'probe' is false, then existing vaue is returned. if 'probe' is true, then the camera is asked for the most recent value. if this is not possible, then en error is reported and last value returned. This value can not be read from camera, so last commanded value is returned. if not available then *dataValid is set to false.

Reimplemented in UCamDevGigE, and UCamPwc.

References vshutter.

Referenced by UComCam::setFromCam(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().

char * UCamDevBase::getWBModeAsString ( int  mode,
char *  strBuff 
)
static

Convert a WB mode to a descriptive string. 'strFuff most be a buffer of at least 10 bytes. a pointer to the buffer, where the mode-string is filled.

Referenced by getWhiteBalance().

int UCamDevBase::getWBModeFromString ( const char *  mode)

Convert white ballance mode to integer. The modes are 'auto' indoor' 'outdoor' 'flurocent' and 'manual'. the mode, and auto, if mode is not recognized.

Referenced by getWhiteBalance().

virtual bool UCamDevBase::getWhiteBalance ( bool  ,
int *  ,
int *  ,
int *   
)
inlinevirtual

Get white balance values if 'probe' the the camera is asked, otherwise previous value is returned unchecked. If one or more of the following pointers are non-zero the integer value is returned.

Reimplemented in UCamPwc, and UCamDevGigE.

References getWBModeAsString(), and getWBModeFromString().

Referenced by UComCam::setFromCam(), and UCamDevGuppy::~UCamDevGuppy().

unsigned int UCamDevBase::getWidth ( )
inline

Get image width in pixels from last captured image.

References frameWidth.

Referenced by UCamMounted::getMtoPix(), UCamPush::print(), UCamPwc::readFramesThread(), UComCam::setFromCam(), testRadErr(), testVideo(), testVideo2(), and testVideo3().

void UCamDevBase::gotNewImage ( UImage rgb)

Called when a new image is available. NB! this function should not be called in camera thread, but by the main server thread,

Parameters
imageis the new image in any colour format (and may be locked for driver purposes)

References cam, and UCamBase::gotNewImage().

Referenced by callGotNewDataWithObject(), makeTriggerPulse(), UCamPwc::readFramesThread(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().

void UCamDevBase::imageSizeChanged ( double  iResFactor)

Set the parameters derived from resolution, i.e. conversion matrix, radial error valeues etc. but at this level just the resolution factor.

References cam, and UCamBase::imageSizeChanged().

Referenced by deviceExist(), UCamPwc::getDeviceInfo(), UCamPwc::protSetDeviceSizeAndSpeed(), UCamDevGigE::setDevice(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().

void UCamDevBase::imgUpdated ( )

Got new image - this is a call to inform server thread that an new-image event has occured for this camera device. - sets a flag and requests the image when main thread is ready.

References cam, and UCamBase::imgUpdated().

Referenced by makeTriggerPulse(), and UCamDevGuppy::~UCamDevGuppy().

bool UCamDevBase::isCameraOpen ( )
inline
bool UCamDevBase::isLog ( )
inline

Is logging set to true

References UVariable::getBool(), setReplay(), and varLog.

Referenced by UCamMounted::logImage().

bool UCamDevBase::isReplay ( )
inline

Is logging set to true

References UVariable::getBool(), and varReplay.

virtual bool UCamDevBase::isThisA ( USupportedCamTypes  thisType)
inlinevirtual

Is the camera of type PWC

This determines a number of possibe additional options, and allow pointer cast to the more specific driver class - not nice but saved time to rewrite e.g. the pan-tilt settings.

Parameters
camTypeis one of the supported camera types - such as PWC or IEEE1394.
Returns
true if camera is of this base-type - i.e. can be safely typecast to a more specific class.

References camType.

Referenced by UCamPool::makeDevice().

virtual bool UCamDevBase::makeTriggerPulse ( )
inlinevirtual

Trigger a new set of images, if this is allowed by the camera. Does nothing if not connected and if external trigger is not available.

Returns
true if calls were successfull.

References gotNewImage(), and imgUpdated().

Referenced by UFunctionCam::handleCamSetCommand(), and UCamDevGuppy::~UCamDevGuppy().

bool UCamDevBase::needNewPushData ( )

Request to test push commands for need of new data. If new data is needed then 'gotNewImage()' should be called.

Returns
true if data is needed.

References cam, and UCamBase::needNewPushData().

Referenced by setCam(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().

virtual bool UCamDevBase::openDevice ( )
inlinevirtual

Open device and set size and framerate as set in frameHeight, frameWidth and frameRate variables. If 'readThreadNormal' = false, no read thread is started. and image capturing and timestamp is disabled. (captureImage will fail)

Reimplemented in UCamDevGigE, and UCamPwc.

Referenced by UComCam::setCamDevice(), testGuppy(), testRadErr(), testVideo(), testVideo3(), and UCamDevIeee1394::~UCamDevIeee1394().

virtual bool UCamDevBase::openDeviceDefault ( )
inlinevirtual

Open devise to get default camera parameters. true if sucessfull.

Reimplemented in UCamDevGigE, and UCamPwc.

Referenced by UCamPool::findDevices(), UCamRad::getImageSnapshot(), getLockedNewImage(), UComCam::setFromCam(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().

virtual bool UCamDevBase::setBrightness ( int  brightness)
inlinevirtual

Set brightness in camera - normal value is 0x8000 and range is 0..0xFFF0

Reimplemented in UCamPwc.

References vbrightness.

void UCamDevBase::setCam ( UCamBase camRef)
inline

Set reference to camera, so that camera cam be informed when a new image has arrived

References cam, getImageSnapshot(), and needNewPushData().

Referenced by UCamBase::UCamBase().

virtual bool UCamDevBase::setColour ( int  colour)
inlinevirtual

Set colour saturation in camera - normal value is 0x8000 and range is 0..0xFFF0

Reimplemented in UCamPwc.

References vcolour.

virtual bool UCamDevBase::setCompPref ( int  value)
inlinevirtual

Set compression preference. This tells the camera the preferred compression ratio. If framerate and image size is too high for the selected compression ratio, then a higher compression is used. 0 = no compression 1 = small 2 = more 3 = highest compression. resolution 640x480 always uses some compression (USB1.1) Compression is visible as blocks of 4x4 pixels get a bit too similar. Returns true if setting is send to camera.

Reimplemented in UCamPwc.

References vcompressionPref.

Referenced by UComCam::setCamDevice().

virtual bool UCamDevBase::setContour ( int  value = 0x1000)
inlinevirtual

Set led speed time is in miliseconds. (on,off): (0,0) = OFF, (100,0) = ON, (200,800) = 1 sec blink with 20% on. Returns true if set. Get setting or last setting Set led on Is led on - sometime Set led blink proportional to framerate. That is on in 200 ms and off in 5/frameRate seconds. Set the contour function in camera. This is an edge sharpener to compensate for lack of bandwidth (horizontal lines only. The range is 0 to 0xFFFF. The value 0x0 is no contour correction. If set negative (e.g. -1) the camera selects an appropriate value. true if command issued.

Reimplemented in UCamPwc.

References vcontour.

Referenced by UComCam::setCamDevice().

virtual bool UCamDevBase::setContrast ( int  contrast)
inlinevirtual

Set contrast in camera - normal value is 0x8000 and range is 0..0xFFF0

Reimplemented in UCamPwc.

References vcontrast.

virtual bool UCamDevBase::setDataChannel ( int  )
inlinevirtual

Set data source channel on a source device, where it is supported. Returns true if successful. On successful return the name of the channel is available by getDataChannelName().

Reimplemented in UCamPwc.

Referenced by UComCam::setCamDevice().

bool UCamDevBase::setDevice ( const int  width,
const int  height,
const int  framesPerSec 
)
virtual
void UCamDevBase::setDeviceNumber ( int  deviceNum)
inline

Set device number for this device.

NB! this should be set only when the camera is closed as no check exist to see if it chenges while the camera is open.

References devNum.

Referenced by UCamPool::findDevices(), UCamPool::makeDevice(), testRadErr(), testVideo(), testVideo2(), and testVideo3().

virtual bool UCamDevBase::setExternalTrigger ( bool  ,
bool *  supported 
)
inlinevirtual

Set external trigger

Parameters
valueset to external trigger if true, else internal (free run) trigger.
supportedis set true if external trigger is supported by device.
Returns
true if value is set as specified.

Referenced by UFunctionCam::handleCamSetCommand(), and UCamDevGuppy::~UCamDevGuppy().

virtual bool UCamDevBase::setGain ( int  )
inlinevirtual

Set gain value. A negative value (-1) sets automatic gain. A positive value in range 0..0xFFFF is video gain in camera. 0 is low gain (but not zero). true if set successful - i.e. camera could be locked and the function is supported by camera.

Reimplemented in UCamPwc, and UCamDevGigE.

Referenced by UComCam::setCamDevice(), testVideo3(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().

virtual bool UCamDevBase::setGamma ( int  gamma)
inlinevirtual

Set gamma correction value. The default setting is 0x8000 (32768), Value 0 is assumed to be linear. So gamma > 1.0 is possible only.

Reimplemented in UCamPwc.

References vgamma.

void UCamDevBase::setImageNumber ( unsigned long  serial)
inline

Set image serial number

References imageNumber.

Referenced by UComCam::setCamDevice().

void UCamDevBase::setInitialized ( bool  value)
inline

Set camera as initialized

References initialized.

Referenced by UCamPool::findDevices(), and UCamPool::makeDevice().

void UCamDevBase::setLog ( bool  value)

Set value of log-variable - if true, then all used images are logged.

References UVariable::setBool(), and varLog.

Referenced by callGotNewDataWithObject(), and UFunctionCam::handleCamSetCommand().

virtual void UCamDevBase::setPushBuffer ( UImage )
inlinevirtual

Set image push image buffer - if one buffer is needed only.

Parameters
imgis the image buffer - typically from image pool.

Referenced by UCamPool::setResource(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().

void UCamDevBase::setReplay ( bool  value)

Set value of replay-variable - if true, then image may be set from replay.

References UVariable::setBool(), and varReplay.

Referenced by UFunctionCam::handleCamSetCommand(), and isLog().

virtual bool UCamDevBase::setShutter ( int  )
inlinevirtual

Manual control with camera intensity gain and shutter speed. NB! This routine does not work - it just sets shutter and AGC to automatic. Just kept for future enhancements.

Parameters
shutis either -1 for auto or a 16bit value range [0..65537] true if no error occured.

Reimplemented in UCamDevGigE, and UCamPwc.

Referenced by UComCam::setCamDevice(), testVideo3(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().

void UCamDevBase::setTypeName ( const char *  newName)
void UCamDevBase::setVarPool ( UVarPool vpd)
inline

Set pointer to established var-pool structure for locally maintained variables

References createVars(), and vars.

Referenced by UCamBase::setVarPool().

virtual bool UCamDevBase::setVideoCap ( int  ,
int  ,
int  ,
int   
)
inlinevirtual

Set all 4 video control values in one call - normal value is 0x8000 and range is 0..0xFFF0.

Reimplemented in UCamPwc.

Referenced by UComCam::setCamDevice().

virtual bool UCamDevBase::setWhiteBalance ( int  ,
int  ,
int   
)
inlinevirtual

Set white balance correction values. The mode can be one of the following values: PWC_WB_AUTO, PWC_WB_MANUAL, PWC_WB_INDOOR, PWC_WB_OUTDOOR, PWC_WB_FL (flurocent). Red and blue gain is used in MANUAL mode only and in a range from 0 to 0x7FFF, where 0x4000 are assumed to be neutral (equal to gain in green channel) true if successful.

Reimplemented in UCamPwc.

Referenced by UComCam::setCamDevice(), and UCamDevGuppy::~UCamDevGuppy().

Member Data Documentation

UCamBase* UCamDevBase::cam
protected

Pointer to the camera using this device and thus need information on events in this camera device.

Referenced by gotNewImage(), imageSizeChanged(), imgUpdated(), needNewPushData(), setCam(), and UCamDevBase().

int UCamDevBase::cam_fd
protected
bool UCamDevBase::cameraOpen
protected
char UCamDevBase::camName[MAX_CAM_DEV_NAME_LENGTH]
protected
USupportedCamTypes UCamDevBase::camType
protected
int UCamDevBase::devNum
protected
int UCamDevBase::frameHeight
protected
int UCamDevBase::frameRate
protected
int UCamDevBase::frameWidth
protected
unsigned long UCamDevBase::imageNumber
protected

Serial number for next used image. images not used are not counted - see imCnt.

Referenced by UCamDevGigE::frameToImage(), getImageNumber(), UCamPwc::readFramesThread(), setImageNumber(), UCamDevBase(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().

int UCamDevBase::imCnt
protected

Image count since last camera device were last opened

Referenced by getLockedNewImage(), UCamPwc::protCloseDevice(), UCamPwc::readFramesThread(), and UCamDevBase().

UImage* UCamDevBase::imgBuff[RAW_IMAGEBUFFER_MAX_CNT]
protected
int UCamDevBase::imgBuffNext
protected
bool UCamDevBase::initialized
protected
const int UCamDevBase::MAX_CAM_DEV_NAME_LENGTH = 100
static
const int UCamDevBase::MAX_IMAGE_WIDTH = 640
static

Max image size, used for size reference in pixel size calculation, and should not be changed from 640x480 - also used for by radial error calculation matrix.

Referenced by UCamPwc::getDeviceInfo(), UCamPwc::protSetDeviceSizeAndSpeed(), UCamRad::saveRadialCorrectionMatrix(), UCamDevGigE::setDevice(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().

const int UCamDevBase::RAW_IMAGEBUFFER_MAX_CNT = 5
staticprotected

size of image buffer for use by the read thread.

Referenced by getLockedNewImage(), UCamDevBase(), and ~UCamDevBase().

UVariable* UCamDevBase::varCamName
protected

camera name from camera

Referenced by createVars(), setTypeName(), and UCamDevBase().

UVariable* UCamDevBase::varLog
protected

Variable for log flag.

Referenced by createVars(), isLog(), setLog(), and UCamDevBase().

UVariable* UCamDevBase::varReplay
protected

Variable for replay.

Referenced by isReplay(), setReplay(), and UCamDevBase().

UVarPool* UCamDevBase::vars
protected

Pointer to established structure for device deopendent variables

Referenced by createVars(), setVarPool(), UCamDevBase(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().

int UCamDevBase::vbrightness
protected

Image brightness setting, if supported by camera Value is in range 0..0xffff and -1 is automatic

Referenced by getBrightness(), UCamPwc::getDeviceInfo(), setBrightness(), UCamDevBase(), and UCamDevIeee1394::~UCamDevIeee1394().

int UCamDevBase::vcolour
protected

Image colour saturation setting - if supported by camera Value is in range 0..0xffff and -1 is automatic

Referenced by getColour(), UCamPwc::getDeviceInfo(), setColour(), UCamDevBase(), and UCamDevIeee1394::~UCamDevIeee1394().

int UCamDevBase::vcompressionPref
protected

Compression preference range [0-3]. 0= no compression, ... 3=higest compression.

Referenced by UCamPwc::getCompPref(), getCompPref(), UCamPwc::setCompPref(), setCompPref(), and UCamDevBase().

int UCamDevBase::vcontour
protected

Contour value to sharpen edges in image Value is in range 0..0xffff and -1 is automatic

Referenced by UCamPwc::getContour(), getContour(), UCamPwc::setContour(), setContour(), UCamDevBase(), and UCamDevIeee1394::~UCamDevIeee1394().

int UCamDevBase::vcontrast
protected

Image contrast setting - if supported by camera Value is in range 0..0xffff and -1 is automatic

Referenced by getContrast(), UCamPwc::getDeviceInfo(), setContrast(), and UCamDevBase().

int UCamDevBase::vgain
protected

Video gain. A negative value marks an automatic gain set by camera A positive gain is a manually set gain Value is in range 0..0xffff and -1 is automatic

Referenced by UCamDevGigE::getGain(), UCamPwc::getGain(), getGain(), UCamPwc::setGain(), and UCamDevBase().

int UCamDevBase::vgamma
protected

Image gamma setting - if supported by camera. Value is in range 0..0xffff and -1 is automatic

Referenced by getGamma(), setGamma(), UCamDevBase(), and UCamDevIeee1394::~UCamDevIeee1394().

int UCamDevBase::vshutter
protected

Shutter speed useable range is about 20000 to 65535. A negative value sets the shutter to automatic. Automatic is usualy a long exposure time and a low video gain. Value is in range 0..0xffff and -1 is automatic

Referenced by UCamPwc::getShutter(), UCamDevGigE::getShutter(), getShutter(), UCamPwc::setShutter(), UCamDevBase(), and UCamDevIeee1394::~UCamDevIeee1394().


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