AJA NTV2 SDK  17.1.1.1245
NTV2 SDK 17.1.1.1245
AJAPnp Class Reference

This is a platform-agnostic plug-and-play class that notifies a client when AJA devices are attached/detached, powered on/off, sleep/wake, etc. More...

#include <pnp.h>

Public Member Functions

 AJAPnp ()
 Default constructor. More...
 
virtual ~AJAPnp ()
 Default destructor. More...
 
virtual AJAStatus Install (AJAPnpCallback callback, void *refCon=NULL, uint32_t devices=0)
 Installs the given plug-n-play notification callback function, replacing any callback function that may have been installed previously. If any matching devices are attached to the host, the callback function is immediately called for each attached device with the AJA_Pnp_DeviceAdded message. More...
 
virtual AJAPnpCallback GetCallback () const
 
virtual AJAStatus Uninstall ()
 Uninstalls any previously-installed callback notifier. More...
 
virtual void * GetRefCon () const
 
virtual uint32_t GetPnpDevices () const
 

Detailed Description

This is a platform-agnostic plug-and-play class that notifies a client when AJA devices are attached/detached, powered on/off, sleep/wake, etc.

Bug:
This class has no Linux implementation.

Definition at line 51 of file pnp.h.

Constructor & Destructor Documentation

◆ AJAPnp()

AJAPnp::AJAPnp ( )

Default constructor.

Definition at line 25 of file pnp.cpp.

◆ ~AJAPnp()

AJAPnp::~AJAPnp ( )
virtual

Default destructor.

Definition at line 31 of file pnp.cpp.

Member Function Documentation

◆ GetCallback()

AJAPnpCallback AJAPnp::GetCallback ( ) const
virtual
Returns
the address of the currently-installed callback (NULL if none installed).

Definition at line 52 of file pnp.cpp.

◆ GetPnpDevices()

uint32_t AJAPnp::GetPnpDevices ( ) const
virtual
Returns
the current bit mask that filters which devices to include or ignore (see implementation).

Definition at line 66 of file pnp.cpp.

◆ GetRefCon()

void * AJAPnp::GetRefCon ( ) const
virtual
Returns
the currently installed reference cookie.

Definition at line 59 of file pnp.cpp.

◆ Install()

AJAStatus AJAPnp::Install ( AJAPnpCallback  callback,
void *  refCon = NULL,
uint32_t  devices = 0 
)
virtual

Installs the given plug-n-play notification callback function, replacing any callback function that may have been installed previously. If any matching devices are attached to the host, the callback function is immediately called for each attached device with the AJA_Pnp_DeviceAdded message.

Parameters
[in]callbackSpecifies a pointer to a client-defined function to be called when AJA devices sleep/wake or are attached/detached to/from the host. If non-NULL, must be valid.
[in]refConSpecifies a pointer-sized reference cookie that gets passed to the callback function. Defaults to NULL.
[in]devicesSpecifies a bit mask that filters which devices to include/ignore (see implementation). Use zero (the default) to see all possible devices.
Bug:
The current Windows implementation doesn't automatically invoke the callback for each attached device. As a workaround, the caller must explicitly enumerate the devices immediately before or after calling this function.
Returns
AJA_STATUS_SUCCESS Install succeeded AJA_STATUS_FAIL Install failed

Definition at line 38 of file pnp.cpp.

◆ Uninstall()

AJAStatus AJAPnp::Uninstall ( )
virtual

Uninstalls any previously-installed callback notifier.

Returns
AJA_STATUS_SUCCESS Uninstall succeeded AJA_STATUS_FAIL Uninstall failed

Definition at line 45 of file pnp.cpp.


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