Spinnaker C++
2.6.0.0
Public Member Functions | Friends | List of all members
Interface Class Reference

An interface object which holds a list of cameras. More...

Inheritance diagram for Interface:
IInterface

Public Member Functions

virtual ~Interface (void)
 Virtual Destructor. More...
 
CameraList GetCameras (bool updateCameras=true) const
 Returns a list of cameras available on this interface. More...
 
bool UpdateCameras ()
 Updates the list of cameras on this interface. More...
 
GenApi::INodeMapGetTLNodeMap () const
 Gets a nodeMap that is generated from a GenICam XML file for the GenTL interface Module. More...
 
void RegisterEventHandler (EventHandler &evtHandlerToRegister)
 Registers an event handler for the interface Event handlers are automatically cleaned up when an interface is removed, and must be registered to interfaces as they arrive. More...
 
void UnregisterEventHandler (EventHandler &evtHandlerToUnregister)
 Unregisters an event handler for the interface. More...
 
bool IsInUse () const
 Checks if the interface is in use by any camera objects. More...
 
void SendActionCommand (unsigned int deviceKey, unsigned int groupKey, unsigned int groupMask, unsigned long long actionTime=0, unsigned int *pResultSize=0, ActionCommandResult results[]=NULL) const
 Broadcast an Action Command to all devices on interface. More...
 
bool IsValid ()
 IsValid Checks a flag to determine if interface is still valid for use. More...
 
- Public Member Functions inherited from IInterface
virtual ~IInterface ()
 

Friends

class InterfaceInternal
 

Additional Inherited Members

- Public Attributes inherited from IInterface
TransportLayerInterface TLInterface
 
- Protected Member Functions inherited from IInterface
 IInterface ()
 
 IInterface (const IInterface &)
 
IInterfaceoperator= (const IInterface &)
 
- Protected Attributes inherited from IInterface
InterfaceData * m_pInterfaceData
 

Detailed Description

An interface object which holds a list of cameras.

Constructor & Destructor Documentation

virtual ~Interface ( void  )
virtual

Virtual Destructor.

Member Function Documentation

CameraList GetCameras ( bool  updateCameras = true) const
virtual

Returns a list of cameras available on this interface.

This call returns either usb3 vision or gige vision cameras depending on the underlying transport layer of this interface. The camera list object will reference count the cameras that it holds. It is important that the CameraList is destroyed or is cleared before System::ReleaseInstance() can be called or an InterfaceList that holds this interface can be cleared.

See Also
System::ReleaseInstance()
InterfaceList::Clear()
CameraList::Clear()
Parameters
updateCamerasA flag used to issue an updateCameras() call internally before getting the camera list
Returns
An CameraList object that contains a list of cameras on this interface.

Implements IInterface.

GenApi::INodeMap& GetTLNodeMap ( ) const
virtual

Gets a nodeMap that is generated from a GenICam XML file for the GenTL interface Module.

Returns
A reference to a INodeMap object.

Implements IInterface.

bool IsInUse ( ) const
virtual

Checks if the interface is in use by any camera objects.

Returns
Returns true if the interface is in use and false otherwise.

Implements IInterface.

bool IsValid ( )
virtual

IsValid Checks a flag to determine if interface is still valid for use.

Returns
If interface is valid or not

Implements IInterface.

void RegisterEventHandler ( EventHandler evtHandlerToRegister)
virtual

Registers an event handler for the interface Event handlers are automatically cleaned up when an interface is removed, and must be registered to interfaces as they arrive.

Note that GEV interfaces experience arrival/removal events when the IP information changes, similar to GEV cameras. Please refer to the EnumerationEvents example for recommended use.

See Also
InterfaceEventHandler
Parameters
evtHandlerToRegisterThe event handler to register for the interface

Implements IInterface.

void SendActionCommand ( unsigned int  deviceKey,
unsigned int  groupKey,
unsigned int  groupMask,
unsigned long long  actionTime = 0,
unsigned int *  pResultSize = 0,
ActionCommandResult  results[] = NULL 
) const
virtual

Broadcast an Action Command to all devices on interface.

Parameters
deviceKeyThe Action Command's device key
groupKeyThe Action Command's group key
groupMaskThe Action Command's group mask
actionTime(Optional) Time when to assert a future action. Zero means immediate action.
pResultSize(Optional) The number of results in the results array. The value passed should be equal to the expected number of devices that acknowledge the command. Returns the number of received results. If this parameter is 0 or NULL, the function will return as soon as the command has been broadcasted.
results(Optional) An Array with *pResultSize elements to hold the action command result status. The buffer is filled starting from index 0. If received results are less than expected number of devices that acknowledge the command, remaining results are not changed. If received results are more than expected number of devices that acknowledge the command, extra results are ignored and not appended to array. This parameter is ignored if pResultSize is 0. Thus this parameter can be NULL if pResultSize is 0 or NULL.

Implements IInterface.

void UnregisterEventHandler ( EventHandler evtHandlerToUnregister)
virtual

Unregisters an event handler for the interface.

See Also
InterfaceEventHandler
Parameters
evtHandlerToUnregisterThe event handler to unregister from the interface

Implements IInterface.

bool UpdateCameras ( )
virtual

Updates the list of cameras on this interface.

This function needs to be called before any cameras can be discovered using GetCameras(). System::GetCameras() will automatically call this function for each interface it enumerates. If the list changed after the last time System::GetCameras() or UpdateCameras() was called then the return value will be true, otherwise it is false.

See Also
System::GetCameras()
GetCameras()
Returns
true if cameras changed on interface and false otherwise.

Implements IInterface.

Friends And Related Function Documentation

friend class InterfaceInternal
friend

The documentation for this class was generated from the following file:
Contact Support Spinnaker® SDK Programmer's Guide and API Reference