AURobotServers
4
|
#include <ucamdevbase.h>
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 | |
UCamBase * | cam |
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 |
UImage * | imgBuff [RAW_IMAGEBUFFER_MAX_CNT] |
int | imgBuffNext |
bool | initialized |
UVariable * | varCamName |
camera name from camera More... | |
UVariable * | varLog |
Variable for log flag. More... | |
UVariable * | varReplay |
Variable for replay. More... | |
UVarPool * | vars |
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 |
The base class for camera device interface classes
@author Christian Andersen <jca@oersted.dtu.dk>
typedef enum UCamDevBase::camTypes UCamDevBase::USupportedCamTypes |
Basic camera types that are supported.
Basic camera types that are supported.
UCamDevBase::UCamDevBase | ( | ) |
Constructor
References cam, cam_fd, cameraOpen, camName, devNum, frameHeight, frameRate, frameWidth, imageNumber, imCnt, imgBuff, imgBuffNext, initialized, MAX_CAM_DEV_NAME_LENGTH, RAW_IMAGEBUFFER_MAX_CNT, varCamName, varLog, varReplay, vars, vbrightness, vcolour, vcompressionPref, vcontour, vcontrast, vgain, vgamma, and vshutter.
|
virtual |
Destructor
References imgBuff, and RAW_IMAGEBUFFER_MAX_CNT.
|
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().
|
inlinevirtual |
close if the device is open
Reimplemented in UCamDevGigE, and UCamPwc.
References setDevice().
Referenced by UCamPool::findDevices(), UCamPool::makeDevice(), UComCam::setCamDevice(), testGuppy(), testVideo2(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().
|
virtual |
Create locally maintained variables - if any
References UVarPool::addVar(), UVarPool::addVarA(), varCamName, varLog, and vars.
Referenced by setVarPool(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().
|
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().
|
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().
|
inline |
Get camera name - old method name - use getName().
References camName.
Referenced by UCamPool::findDevices(), UCamBase::getCamName(), UFunctionCam::handleCamsGetCommand(), UCamPool::makeDevice(), UCamPush::print(), UCamPwc::readFramesThread(), UComCam::setFromCam(), testRadErr(), testVideo(), testVideo2(), testVideo3(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().
|
inline |
Get device handle for external manipulations and access
References cam_fd.
Referenced by UCamPwc::getDeviceInfo(), UCamPanTiltDevice::pantiltSetPosition(), UCamPanTiltDevice::protPantiltGetPosition(), UCamPanTiltDevice::protPantiltGetRange(), UCamPanTiltDevice::protPantiltReset(), UCamPwc::readFramesThread(), UCamPwc::setDataChannel(), testVideo(), and testVideo2().
|
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().
|
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().
|
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().
|
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().
|
inlinevirtual |
Get current data channel setting. Returns -1 if channel setting is not supported.
Reimplemented in UCamPwc.
Referenced by UComCam::setFromCam().
|
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().
|
inline |
Det device number - may translate into /dev/videoX if a PWC or other video device
References devNum.
Referenced by UFuncCog::centerOfGravity(), UCamDevGigE::closeDevice(), UFuncFocus::doFocus(), UCamDevGigE::frameToImage(), UCamPool::getCam(), UCamBase::getDevNum(), UCamPool::getFirstCamDevice(), UFunctionCam::handleCamsGetCommand(), UFunctionCamGmk::handleGmkGetCommand(), UFunctionCamPath::handlePathGetCommand(), UImageLog::logImage(), UCamPool::makeDevice(), UCamPush::print(), UComCam::setFromCam(), testVideo2(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().
|
inlinevirtual |
Get external trigger support flag
supported | is set true if external trigger is supported by device. |
Referenced by UCamDevGuppy::~UCamDevGuppy().
|
inlinevirtual |
Get current frame rate setting
Reimplemented in UCamDevGigE.
References frameRate.
Referenced by UCamPush::print(), UComCam::setFromCam(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().
|
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().
|
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().
|
inline |
Get camera pixel height from last captured image
References frameHeight.
Referenced by UCamMounted::getMtoPix(), UCamPush::print(), UCamPwc::readFramesThread(), UComCam::setFromCam(), testRadErr(), testVideo(), testVideo2(), and testVideo3().
|
inline |
Get image serial number
References imageNumber.
Referenced by UCalibrate::findGmk(), and UComCam::setFromCam().
|
virtual |
Get new image - the newest available. if 'image' == NULL, then get and discard an image.
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().
|
inline |
Get camera name.
References camName, and setTypeName().
Referenced by testVideo3(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().
|
inline |
Get pixel size relative to 640x480.
Referenced by UCamRad::setCameraParameters(), and UCamRad::updateLensParams().
|
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().
|
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().
|
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().
|
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,
image | is 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().
|
inline |
Is camera open in streaming mode.
References cameraOpen.
Referenced by UCamPool::findDevices(), UCamRad::getImageSnapshot(), UCamDevGigE::getImageSnapshot(), getLockedNewImage(), UFunctionCam::handleCamPushCommand(), UFunctionCam::handleCamSetCommand(), UCamPanTiltDevice::pantiltSetPosition(), UCamPush::print(), UCamPanTiltDevice::protPantiltGetPosition(), UCamPanTiltDevice::protPantiltGetRange(), UCamPanTiltDevice::protPantiltReset(), UComCam::setCamDevice(), UComCam::setFromCam(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().
|
inline |
Is logging set to true
References UVariable::getBool(), setReplay(), and varLog.
Referenced by UCamMounted::logImage().
|
inline |
Is logging set to true
References UVariable::getBool(), and varReplay.
|
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.
camType | is one of the supported camera types - such as PWC or IEEE1394. |
References camType.
Referenced by UCamPool::makeDevice().
|
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.
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.
References cam, and UCamBase::needNewPushData().
Referenced by setCam(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().
|
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().
|
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().
|
inlinevirtual |
Set brightness in camera - normal value is 0x8000 and range is 0..0xFFF0
Reimplemented in UCamPwc.
References vbrightness.
|
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().
|
inlinevirtual |
|
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().
|
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().
|
inlinevirtual |
|
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().
|
virtual |
implement these settings and leave the device open.
Reimplemented in UCamDevGigE, and UCamPwc.
References frameHeight, frameRate, and frameWidth.
Referenced by closeDevice(), UFuncKinect::run(), UComCam::setCamDevice(), testRadErr(), testVideo(), testVideo2(), testVideo3(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().
|
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().
|
inlinevirtual |
Set external trigger
value | set to external trigger if true, else internal (free run) trigger. |
supported | is set true if external trigger is supported by device. |
Referenced by UFunctionCam::handleCamSetCommand(), and UCamDevGuppy::~UCamDevGuppy().
|
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().
|
inlinevirtual |
|
inline |
|
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().
|
inlinevirtual |
Set image push image buffer - if one buffer is needed only.
img | is 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().
|
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.
shut | is 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 | ) |
Set camera name.
References camName, MAX_CAM_DEV_NAME_LENGTH, UVariable::setValues(), and varCamName.
Referenced by UCamDevGigE::deviceExist(), getName(), and UCamBase::setTypeName().
|
inline |
Set pointer to established var-pool structure for locally maintained variables
References createVars(), and vars.
Referenced by UCamBase::setVarPool().
|
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().
|
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().
|
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().
|
protected |
Referenced by UCamPwc::deviceExist(), UCamPwc::getBrightness(), getCamFd(), UCamPwc::getColour(), UCamPwc::getCompPref(), UCamPwc::getContour(), UCamPwc::getContrast(), UCamPwc::getDeviceInfo(), UCamPwc::getGain(), UCamPwc::getGamma(), UCamPwc::getWhiteBalance(), UCamPwc::isValidDevice(), UCamPwc::protCloseDevice(), UCamPwc::protOpenDevice(), UCamPwc::protSetDeviceSizeAndSpeed(), UCamPwc::readFramesThread(), UCamPwc::setBrightness(), UCamPwc::setColour(), UCamPwc::setCompPref(), UCamPwc::setContour(), UCamPwc::setContrast(), UCamPwc::setGain(), UCamPwc::setGamma(), UCamPwc::setShutter(), UCamPwc::setVideoCap(), UCamPwc::setWhiteBalance(), and UCamDevBase().
|
protected |
Camera is open - straming images
Referenced by UCamDevGigE::closeDevice(), UCamDevGigE::deviceExist(), UCamPwc::getDeviceInfo(), UCamPwc::isCameraOpen(), isCameraOpen(), UCamDevGigE::openDeviceDefault(), UCamPwc::protCloseDevice(), UCamPwc::protOpenDevice(), UCamPwc::protSetDeviceSizeAndSpeed(), UCamPwc::readFramesThread(), UCamPwc::setGain(), UCamPwc::setShutter(), UCamPwc::setWhiteBalance(), UCamDevBase(), UCamPwc::UCamPwc(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().
|
protected |
Camera name - as obtained from device
Referenced by getCameraName(), UCamPwc::getDeviceInfo(), getName(), setTypeName(), UCamDevBase(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().
|
protected |
|
protected |
file descriptor for camera device
Device number - translates to /dev/video0, -1, -2 ... if video device or something else if it is a IEEE1394 device
Referenced by UCamPwc::deviceExist(), getDeviceNumber(), UCamDevGigE::getImageSnapshot(), UCamDevGigE::openDeviceDefault(), UCamPwc::protOpenDevice(), UCamPwc::protSetDeviceSizeAndSpeed(), UCamPwc::readFramesThread(), setDeviceNumber(), UCamPwc::startReadThread(), UCamDevBase(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().
|
protected |
Size of images read from device (expected size)
Referenced by UCamPwc::getDeviceInfo(), getHeight(), UCamPwc::openDevice(), UCamDevGigE::openDeviceDefault(), UCamPwc::protSetDeviceSizeAndSpeed(), UCamPwc::readFramesThread(), UCamDevGigE::setDevice(), setDevice(), UCamDevBase(), UCamPwc::UCamPwc(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().
|
protected |
Framerate from camera (frames/sec (rounded)
Referenced by UCamPwc::getDeviceInfo(), getFrameRate(), UCamDevGigE::getFrameRate(), UCamPwc::openDevice(), UCamPwc::protSetDeviceSizeAndSpeed(), UCamPwc::setDevice(), UCamDevGigE::setDevice(), setDevice(), UCamPwc::setLedFrameRate(), UCamDevBase(), UCamDevGigE::UCamDevGigE(), UCamPwc::waitAFrame(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().
|
protected |
Size of images read from device (expected size)
Referenced by UCamPwc::getDeviceInfo(), getWidth(), UCamPwc::openDevice(), UCamDevGigE::openDeviceDefault(), UCamPwc::protSetDeviceSizeAndSpeed(), UCamPwc::readFramesThread(), UCamDevGigE::setDevice(), setDevice(), UCamDevBase(), UCamPwc::UCamPwc(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().
|
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().
|
protected |
Image count since last camera device were last opened
Referenced by getLockedNewImage(), UCamPwc::protCloseDevice(), UCamPwc::readFramesThread(), and UCamDevBase().
|
protected |
Image buffer for images read by read thread
Referenced by getLockedNewImage(), UCamDevGigE::openDeviceDefault(), UCamPwc::readFramesThread(), UCamDevBase(), UCamDevGigE::UCamDevGigE(), ~UCamDevBase(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().
|
protected |
Next image buffer to use
Referenced by getLockedNewImage(), UCamDevGigE::openDeviceDefault(), UCamPwc::readFramesThread(), UCamDevBase(), and UCamDevGigE::UCamDevGigE().
|
protected |
Camera is initialized
Referenced by UCamDevGigE::deviceExist(), setInitialized(), UCamDevBase(), UCamDevGigE::~UCamDevGigE(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().
|
static |
Max length of camera name
Referenced by UCamPwc::getDeviceInfo(), UComCam::setFromCam(), setTypeName(), UCamDevBase(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().
|
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().
|
staticprotected |
size of image buffer for use by the read thread.
Referenced by getLockedNewImage(), UCamDevBase(), and ~UCamDevBase().
|
protected |
camera name from camera
Referenced by createVars(), setTypeName(), and UCamDevBase().
|
protected |
Variable for log flag.
Referenced by createVars(), isLog(), setLog(), and UCamDevBase().
|
protected |
Variable for replay.
Referenced by isReplay(), setReplay(), and UCamDevBase().
|
protected |
Pointer to established structure for device deopendent variables
Referenced by createVars(), setVarPool(), UCamDevBase(), UCamDevGuppy::~UCamDevGuppy(), and UCamDevIeee1394::~UCamDevIeee1394().
|
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().
|
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().
|
protected |
Compression preference range [0-3]. 0= no compression, ... 3=higest compression.
Referenced by UCamPwc::getCompPref(), getCompPref(), UCamPwc::setCompPref(), setCompPref(), and UCamDevBase().
|
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().
|
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().
|
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().
|
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().
|
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().