Image Component Library (ICL)
Classes | Public Member Functions | Static Public Member Functions | Static Public Attributes | Private Types | Private Member Functions | Private Attributes | Friends | List of all members

Device struct, used by the DCGrabber class to identify devices. More...

#include <DCDevice.h>

Classes

struct  Mode
 Internally used Mode struct (combination of videomode and framerate) More...
 

Public Member Functions

std::string getTypeID () const
 returns an instances type ID (see also static functions) More...
 
dc1394camera_t * getCam () const
 returns the camera, which is associated with this device (fixed) More...
 
Mode getMode () const
 returns the current mode More...
 
std::vector< ModegetModes () const
 returns a list of supported modes for this device More...
 
std::string getModesInfo () const
 returns a list of supported modes for this device as info-string More...
 
std::string getVendorID () const
 returns the vendor id string from the wrapped camera or "null" if the device is null More...
 
std::string getModelID () const
 returns the model id string from the wrapped camera or "null" if the device is null More...
 
uint64_t getGUID () const
 returns the devices Global Unique ID More...
 
icl32s getUnit () const
 returns the IEEE1394 Unit of the device More...
 
icl32s getUnitSpecID () const
 returns the IEEE1394 UnitSpecID of the device More...
 
std::string getUniqueStringIdentifier () const
 returns a unique string identifier for this device More...
 
bool isNull () const
 returns wheather the device is associated to a dc-camera More...
 
void show (const std::string &title="DCDevice") const
 shows some device information More...
 
bool supports (const Mode &mode) const
 returns whether the Device supports a given mode More...
 
dc1394color_filter_t getBayerFilterLayout () const
 returns the cameras bayer filter layout More...
 
void setISOSpeed (int mbits)
 sets the cameras iso speed More...
 
bool supportsDC800 ()
 returns whether the device supports Firewire B mode More...
 

Static Public Member Functions

static std::string getTypeID (const std::string &model, const std::string &vendor)
 returns a type ID specifier (vendor+" -- "+model) More...
 
static std::string getTypeID (const dc1394camera_t *cam)
 returns getTypeID(cam->model,cam->vendor) More...
 
static void dc1394_reset_bus (bool verbose=false)
 save version to call dc1394_reset_bus (after call all other cams become useless) More...
 

Static Public Attributes

static const DCDevice null
 static null device (m_poCam is null) More...
 

Private Types

enum  BayerFilterMode {
  BF_RGGB = DC1394_COLOR_FILTER_RGGB, BF_GBRG = DC1394_COLOR_FILTER_GBRG, BF_GRBG = DC1394_COLOR_FILTER_GRBG, BF_BGGR = DC1394_COLOR_FILTER_BGGR,
  BF_NONE, BF_FROM_MODE, BF_FROM_FEATURE
}
 

Private Member Functions

 DCDevice (dc1394camera_t *cam)
 Creates a new device (pivate; called by DCGrabber::getDeviceList()) More...
 
void setMode (const Mode &mode)
 sets the current mode of this device More...
 
void reset ()
 resets the camera internally More...
 
void estimateBayerFilterMode ()
 this function is called by the constructor More...
 

Private Attributes

dc1394camera_t * m_poCam
 associated camera (libdc stays the owner of the pointer) More...
 
BayerFilterMode m_eBayerFilterMode
 once estimated this flag is used to identify the current camery type More...
 

Friends

class icl::io::DCGrabber
 DCDevices may only be created by the DCGrabbers private function. More...
 
class icl::io::dc::DCGrabberThread
 DCDevices may only be created by the DCGrabbers private function. More...
 

Detailed Description

Device struct, used by the DCGrabber class to identify devices.

Member Enumeration Documentation

◆ BayerFilterMode

Enumerator
BF_RGGB 
BF_GBRG 
BF_GRBG 
BF_BGGR 
BF_NONE 
BF_FROM_MODE 
BF_FROM_FEATURE 

Constructor & Destructor Documentation

◆ DCDevice()

icl::io::DCDevice::DCDevice ( dc1394camera_t *  cam)
inlineprivate

Creates a new device (pivate; called by DCGrabber::getDeviceList())

Member Function Documentation

◆ dc1394_reset_bus()

static void icl::io::DCDevice::dc1394_reset_bus ( bool  verbose = false)
static

save version to call dc1394_reset_bus (after call all other cams become useless)

◆ estimateBayerFilterMode()

void icl::io::DCDevice::estimateBayerFilterMode ( )
private

this function is called by the constructor

◆ getBayerFilterLayout()

dc1394color_filter_t icl::io::DCDevice::getBayerFilterLayout ( ) const

returns the cameras bayer filter layout

Returns
bayer filter layout
  • 0 if no bayer filter is needed
  • 1 if the bayer filter layout is given by a camera feature
  • otherwise a valid dc1394color_filter_t value

◆ getCam()

dc1394camera_t* icl::io::DCDevice::getCam ( ) const
inline

returns the camera, which is associated with this device (fixed)

◆ getGUID()

uint64_t icl::io::DCDevice::getGUID ( ) const

returns the devices Global Unique ID

◆ getMode()

Mode icl::io::DCDevice::getMode ( ) const
inline

returns the current mode

◆ getModelID()

std::string icl::io::DCDevice::getModelID ( ) const

returns the model id string from the wrapped camera or "null" if the device is null

◆ getModes()

std::vector<Mode> icl::io::DCDevice::getModes ( ) const

returns a list of supported modes for this device

◆ getModesInfo()

std::string icl::io::DCDevice::getModesInfo ( ) const

returns a list of supported modes for this device as info-string

◆ getTypeID() [1/3]

static std::string icl::io::DCDevice::getTypeID ( const std::string &  model,
const std::string &  vendor 
)
static

returns a type ID specifier (vendor+" -- "+model)

◆ getTypeID() [2/3]

static std::string icl::io::DCDevice::getTypeID ( const dc1394camera_t *  cam)
static

returns getTypeID(cam->model,cam->vendor)

◆ getTypeID() [3/3]

std::string icl::io::DCDevice::getTypeID ( ) const
inline

returns an instances type ID (see also static functions)

See also
getTypeID(const std::string&,const std::string &)

◆ getUniqueStringIdentifier()

std::string icl::io::DCDevice::getUniqueStringIdentifier ( ) const

returns a unique string identifier for this device

currently: getModelID + "-" +getGUID()

◆ getUnit()

icl32s icl::io::DCDevice::getUnit ( ) const

returns the IEEE1394 Unit of the device

◆ getUnitSpecID()

icl32s icl::io::DCDevice::getUnitSpecID ( ) const

returns the IEEE1394 UnitSpecID of the device

◆ getVendorID()

std::string icl::io::DCDevice::getVendorID ( ) const

returns the vendor id string from the wrapped camera or "null" if the device is null

◆ isNull()

bool icl::io::DCDevice::isNull ( ) const
inline

returns wheather the device is associated to a dc-camera

◆ reset()

void icl::io::DCDevice::reset ( )
inlineprivate

resets the camera internally

This function may only be called by the DCGrabber

◆ setISOSpeed()

void icl::io::DCDevice::setISOSpeed ( int  mbits)

sets the cameras iso speed

See also
icl::dc::set_iso_speed(int)

◆ setMode()

void icl::io::DCDevice::setMode ( const Mode mode)
private

sets the current mode of this device

This function may only be called by the DCGrabber

◆ show()

void icl::io::DCDevice::show ( const std::string &  title = "DCDevice") const

shows some device information

◆ supports()

bool icl::io::DCDevice::supports ( const Mode mode) const

returns whether the Device supports a given mode

◆ supportsDC800()

bool icl::io::DCDevice::supportsDC800 ( )

returns whether the device supports Firewire B mode

Friends And Related Function Documentation

◆ icl::io::dc::DCGrabberThread

friend class icl::io::dc::DCGrabberThread
friend

DCDevices may only be created by the DCGrabbers private function.

◆ icl::io::DCGrabber

friend class icl::io::DCGrabber
friend

DCDevices may only be created by the DCGrabbers private function.

Member Data Documentation

◆ m_eBayerFilterMode

BayerFilterMode icl::io::DCDevice::m_eBayerFilterMode
private

once estimated this flag is used to identify the current camery type

◆ m_poCam

dc1394camera_t* icl::io::DCDevice::m_poCam
private

associated camera (libdc stays the owner of the pointer)

◆ null

const DCDevice icl::io::DCDevice::null
static

static null device (m_poCam is null)


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