Impact Acquire SDK C++
CameraDescriptionManager Class Reference

Grants access to camera description objects(Device specific interface layout only) (deprecated. More...

#include <mvIMPACT_acquire.h>

Public Member Functions

CameraDescriptionCameraLinkcameraDescriptionCameraLink (const std::string &name) const
 Returns a pointer to a mvIMPACT::acquire::CameraDescriptionCameraLink object specifying the camera description with the given name in the camera description managers internal list.
 
CameraDescriptionCameraLinkcameraDescriptionCameraLink (unsigned int index) const
 Returns a pointer to a mvIMPACT::acquire::CameraDescriptionCameraLink object specifying the camera description found at the given index in the camera description managers internal list.
 
CameraDescriptionDigitalcameraDescriptionDigital (const std::string &name) const
 Returns a pointer to a mvIMPACT::acquire::CameraDescriptionDigital object specifying the camera description with the given name in the camera description managers internal list.
 
CameraDescriptionDigitalcameraDescriptionDigital (unsigned int index) const
 Returns a pointer to a mvIMPACT::acquire::CameraDescriptionDigital object specifying the camera description found at the given index in the camera description managers internal list.
 
 CameraDescriptionManager (const CameraDescriptionManager &src)
 Constructs a new mvIMPACT::acquire::CameraDescriptionManager from an existing one.
 
 CameraDescriptionManager (Device *pDev)
 Constructs a new mvIMPACT::acquire::CameraDescriptionManager object.
 
CameraDescriptionNonStandardcameraDescriptionNonStandard (const std::string &name) const
 Returns a pointer to a mvIMPACT::acquire::CameraDescriptionNonStandard object specifying the camera description with the given name in the camera description managers internal list.
 
CameraDescriptionNonStandardcameraDescriptionNonStandard (unsigned int index) const
 Returns a pointer to a mvIMPACT::acquire::CameraDescriptionNonStandard object specifying the camera description found at the given index in the camera description managers internal list.
 
CameraDescriptionSDIcameraDescriptionSDI (const std::string &name) const
 Returns a pointer to a mvIMPACT::acquire::CameraDescriptionSDI object specifying the camera description with the given name in the camera description managers internal list.
 
CameraDescriptionSDIcameraDescriptionSDI (unsigned int index) const
 Returns a pointer to a mvIMPACT::acquire::CameraDescriptionSDI object specifying the camera description found at the given index in the camera description managers internal list.
 
CameraDescriptionStandardcameraDescriptionStandard (const std::string &name) const
 Returns a pointer to a mvIMPACT::acquire::CameraDescriptionStandard object specifying the camera description with the given name in the camera description managers internal list.
 
CameraDescriptionStandardcameraDescriptionStandard (unsigned int index) const
 Returns a pointer to a mvIMPACT::acquire::CameraDescriptionStandard object specifying the camera description found at the given index in the camera description managers internal list.
 
unsigned int getCLCameraDescriptionCount (void) const
 Returns the number of CameraLink® camera descriptions currently available for the device that constructed this instance of the class.
 
unsigned int getDigitalCameraDescriptionCount (void) const
 Returns the number of non-standard digital camera descriptions currently available for the device that constructed this instance of the class.
 
unsigned int getNonStandardCameraDescriptionCount (void) const
 Returns the number of non-standard camera descriptions currently available for the device that constructed this instance of the class.
 
unsigned int getSDICameraDescriptionCount (void) const
 Returns the number of SDI camera descriptions currently available for the device that constructed this instance of the class.
 
unsigned int getStandardCameraDescriptionCount (void) const
 Returns the number of standard camera descriptions currently available for the device that constructed this instance of the class.
 
unsigned int getTotalCameraDescriptionCount (void) const
 Returns the total number camera descriptions currently available for the device that constructed this instance of the class.
 
CameraDescriptionManageroperator= (const CameraDescriptionManager &rhs)
 Allows assignments of mvIMPACT::acquire::CameraDescriptionManager objects.
 
 ~CameraDescriptionManager ()
 Class destructor.
 

Detailed Description

Grants access to camera description objects(Device specific interface layout only) (deprecated.

Deprecated
Beginning with the release of 3.0.0 of Impact Acquire everything specifically related to frame grabber boards will be considered as deprecated and might be removed without further notice!

This class provides access to the various camera description objects. Each device recognizes a different set of camera descriptions. E.g. a digital frame grabber will not be able to work with analogue cameras. Each camera description class will be derived from mvIMPACT::acquire::CameraDescriptionBase.

Note
Please note that instances of this class will ONLY list camera descriptions that have once been selected by the property mvIMPACT::acquire::CameraSettingsFrameGrabber::type at runtime. This is to save memory. A complete list of camera descriptions available for the current device therefore can only be queried by reading the the translation dictionary of the property mvIMPACT::acquire::CameraSettingsFrameGrabber::type.
#include <mvIMPACT_CPP/mvIMPACT_acquire.h>
#include <algorithm>
#include <iostream>
using namespace std;
using namespace mvIMPACT::acquire;
//-----------------------------------------------------------------------------
template<class T>
class DisplayDictEntry
//-----------------------------------------------------------------------------
{
public:
void operator()( const pair<string, T>& data ) const
{
cout << " [" << data.second << "]: " << data.first << endl;
}
};
//-----------------------------------------------------------------------------
// lists all available camera descriptions for a certain device
int main( int argc, char* argv[] )
//-----------------------------------------------------------------------------
{
DeviceManager devMgr;
Device* pDev = devMgr[0];
if( !pDev )
{
cout << "No device found" << endl;
return 0;
}
// display the name of every camera description available for this device.
// this might be less than the number of camera descriptions available on the system as e.g.
// an analog frame grabber can't use descriptions for digital cameras
std::string<std::string, int> vAvailableDescriptions;
cs.type.getTranslationDict( vAvailableDescriptions );
cout << endl << "Available camera descriptions: " << vAvailableDescriptions.size() << endl
<< "----------------------------------" << endl;
for_each( vAvailableDescriptions.begin(), vAvailableDescriptions.end(), DisplayDictEntry<int>() )
// list all descriptions that already have been selected at least once
CameraDescriptionManager camMgr( pDev );
unsigned int camCnt = camMgr.getCLCameraDescriptionCount();
cout << "Available CL descriptions: " << camCnt << endl;
for( unsigned int a=0; a<camCnt; a++ )
{
cout << " " << camMgr.cameraDescriptionCameraLink( a )->name.read() << endl;
}
camCnt = camMgr.getStandardCameraDescriptionCount();
cout << "Available Std descriptions: " << camCnt << endl;
for( unsigned int b=0; b<camCnt; b++ )
{
cout << " " << camMgr.cameraDescriptionStandard( b )->name.read() << endl;
}
camCnt = camMgr.getNonStandardCameraDescriptionCount();
cout << "Available NonStd descriptions: " << camCnt << endl;
for( unsigned int c=0; c<camCnt; c++ )
{
cout << " " << camMgr.cameraDescriptionNonStandard( c )->name.read() << endl;
}
return 0;
}
PropertyS name
A string property read-only containing the name of this camera description list.
Definition mvIMPACT_acquire.h:21045
Grants access to camera description objects(Device specific interface layout only) (deprecated.
Definition mvIMPACT_acquire.h:21721
CameraDescriptionCameraLink * cameraDescriptionCameraLink(unsigned int index) const
Returns a pointer to a mvIMPACT::acquire::CameraDescriptionCameraLink object specifying the camera de...
Definition mvIMPACT_acquire.h:21923
unsigned int getCLCameraDescriptionCount(void) const
Returns the number of CameraLink® camera descriptions currently available for the device that constru...
Definition mvIMPACT_acquire.h:21911
A class to access frame grabber related camera settings(Device specific interface layout only) (depre...
Definition mvIMPACT_acquire.h:20411
Grants access to devices that can be operated by this software interface.
Definition mvIMPACT_acquire.h:7171
This class and its functions represent an actual device detected by this interface in the current sys...
Definition mvIMPACT_acquire.h:6118
std::string read(int index=0) const
Reads a value from a property.
Definition mvIMPACT_acquire.h:5323
This namespace contains classes and functions belonging to the image acquisition module of this SDK.
Definition mvCommonDataTypes.h:34
Note
This class will only be available for frame grabber devices. For other devices the class constructor will raise an exception.
This class will only be available if mvIMPACT::acquire::Device::interfaceLayout is set to mvIMPACT::acquire::dilDeviceSpecific before the device is opened.

Constructor & Destructor Documentation

◆ CameraDescriptionManager() [1/2]

CameraDescriptionManager ( Device * pDev)
explicit

Constructs a new mvIMPACT::acquire::CameraDescriptionManager object.

[in] A pointer to a mvIMPACT::acquire::Device object obtained from a mvIMPACT::acquire::>DeviceManager object.

◆ CameraDescriptionManager() [2/2]

Constructs a new mvIMPACT::acquire::CameraDescriptionManager from an existing one.

Parameters
srcA constant reference to the mvIMPACT::acquire::CameraDescriptionManager object, this object shall be created from

◆ ~CameraDescriptionManager()

Class destructor.

Member Function Documentation

◆ cameraDescriptionCameraLink() [1/2]

CameraDescriptionCameraLink * cameraDescriptionCameraLink ( const std::string & name) const
inline

Returns a pointer to a mvIMPACT::acquire::CameraDescriptionCameraLink object specifying the camera description with the given name in the camera description managers internal list.

Returns
  • a pointer to a mvIMPACT::acquire::CameraDescriptionCameraLink object specifying the camera description with the given name in the camera description managers internal list if a camera description with name is available.
  • an invalid pointer or reference otherwise.
Parameters
[in]nameThe name of the camera description. This can either be the name of the list like e.g. 'CameraLink_Generic' or the value of the property 'name' of this description like e.g. 'Generic'.

◆ cameraDescriptionCameraLink() [2/2]

CameraDescriptionCameraLink * cameraDescriptionCameraLink ( unsigned int index) const
inline

Returns a pointer to a mvIMPACT::acquire::CameraDescriptionCameraLink object specifying the camera description found at the given index in the camera description managers internal list.

If the index is either equal or higher than the number of CameraLink® camera descriptions
detected for this device an STL out_of_range exception will be thrown.

Parameters
[in]indexThe index of the camera description to return

◆ cameraDescriptionDigital() [1/2]

CameraDescriptionDigital * cameraDescriptionDigital ( const std::string & name) const
inline

Returns a pointer to a mvIMPACT::acquire::CameraDescriptionDigital object specifying the camera description with the given name in the camera description managers internal list.

Returns
  • a pointer to a mvIMPACT::acquire::CameraDescriptionDigital object specifying the camera description with the given name in the camera description managers internal list if a camera description with name is available.
  • an invalid pointer or reference otherwise.
Parameters
[in]nameThe name of the camera description. This can either be the name of the list like e.g. 'Digital_Generic' or the value of the property 'name' of this description like e.g. 'Generic'.

◆ cameraDescriptionDigital() [2/2]

CameraDescriptionDigital * cameraDescriptionDigital ( unsigned int index) const
inline

Returns a pointer to a mvIMPACT::acquire::CameraDescriptionDigital object specifying the camera description found at the given index in the camera description managers internal list.

If the index is either equal or higher than the number of non-standard digital camera descriptions
detected for this device an STL out_of_range exception will be thrown.

Parameters
[in]indexThe index of the camera description to return

◆ cameraDescriptionNonStandard() [1/2]

CameraDescriptionNonStandard * cameraDescriptionNonStandard ( const std::string & name) const
inline

Returns a pointer to a mvIMPACT::acquire::CameraDescriptionNonStandard object specifying the camera description with the given name in the camera description managers internal list.

Returns
  • a pointer to a mvIMPACT::acquire::CameraDescriptionNonStandard object specifying the camera description with the given name in the camera description managers internal list if a camera description with name is available.
  • an invalid pointer or reference otherwise.
Parameters
[in]nameThe name of the camera description. This can either be the name of the list like e.g. 'NonStandard_Generic' or the value of the property 'name' of this description like e.g. 'Generic'.

◆ cameraDescriptionNonStandard() [2/2]

CameraDescriptionNonStandard * cameraDescriptionNonStandard ( unsigned int index) const
inline

Returns a pointer to a mvIMPACT::acquire::CameraDescriptionNonStandard object specifying the camera description found at the given index in the camera description managers internal list.

If the index is either equal or higher than the number of non-standard camera descriptions
detected for this device an STL out_of_range exception will be thrown.

Parameters
[in]indexThe index of the camera description to return

◆ cameraDescriptionSDI() [1/2]

CameraDescriptionSDI * cameraDescriptionSDI ( const std::string & name) const
inline

Returns a pointer to a mvIMPACT::acquire::CameraDescriptionSDI object specifying the camera description with the given name in the camera description managers internal list.

Returns
  • a pointer to a mvIMPACT::acquire::CameraDescriptionSDI object specifying the camera description with the given name in the camera description managers internal list if a camera description with name is available.
  • an invalid pointer or reference otherwise.
Parameters
[in]nameThe name of the camera description. This can either be the name of the list like e.g. 'CameraLink_Generic' or the value of the property 'name' of this description like e.g. 'Generic'.

◆ cameraDescriptionSDI() [2/2]

CameraDescriptionSDI * cameraDescriptionSDI ( unsigned int index) const
inline

Returns a pointer to a mvIMPACT::acquire::CameraDescriptionSDI object specifying the camera description found at the given index in the camera description managers internal list.

If the index is either equal or higher than the number of SDI camera descriptions
detected for this device an STL out_of_range exception will be thrown.

Parameters
[in]indexThe index of the camera description to return

◆ cameraDescriptionStandard() [1/2]

CameraDescriptionStandard * cameraDescriptionStandard ( const std::string & name) const
inline

Returns a pointer to a mvIMPACT::acquire::CameraDescriptionStandard object specifying the camera description with the given name in the camera description managers internal list.

Returns
  • a pointer to a mvIMPACT::acquire::CameraDescriptionStandard object specifying the camera description with the given name in the camera description managers internal list if a camera description with name is available.
  • an invalid pointer or reference otherwise.
Parameters
[in]nameThe name of the camera description. This can either be the name of the list like e.g. 'Standard_Generic' or the value of the property 'name' of this description like e.g. 'Generic'.

◆ cameraDescriptionStandard() [2/2]

CameraDescriptionStandard * cameraDescriptionStandard ( unsigned int index) const
inline

Returns a pointer to a mvIMPACT::acquire::CameraDescriptionStandard object specifying the camera description found at the given index in the camera description managers internal list.

If the index is either equal or higher than the number of standard camera descriptions
detected for this device an STL out_of_range exception will be thrown.

Parameters
[in]indexThe index of the camera description to return

◆ getCLCameraDescriptionCount()

unsigned int getCLCameraDescriptionCount ( void ) const
inline

Returns the number of CameraLink® camera descriptions currently available for the device that constructed this instance of the class.

◆ getDigitalCameraDescriptionCount()

unsigned int getDigitalCameraDescriptionCount ( void ) const
inline

Returns the number of non-standard digital camera descriptions currently available for the device that constructed this instance of the class.

◆ getNonStandardCameraDescriptionCount()

unsigned int getNonStandardCameraDescriptionCount ( void ) const
inline

Returns the number of non-standard camera descriptions currently available for the device that constructed this instance of the class.

◆ getSDICameraDescriptionCount()

unsigned int getSDICameraDescriptionCount ( void ) const
inline

Returns the number of SDI camera descriptions currently available for the device that constructed this instance of the class.

◆ getStandardCameraDescriptionCount()

unsigned int getStandardCameraDescriptionCount ( void ) const
inline

Returns the number of standard camera descriptions currently available for the device that constructed this instance of the class.

◆ getTotalCameraDescriptionCount()

unsigned int getTotalCameraDescriptionCount ( void ) const
inline

Returns the total number camera descriptions currently available for the device that constructed this instance of the class.

Since
2.1.4

◆ operator=()

CameraDescriptionManager & operator= ( const CameraDescriptionManager & rhs)
inline

Allows assignments of mvIMPACT::acquire::CameraDescriptionManager objects.