AJA NTV2 SDK  17.1.1.1245
NTV2 SDK 17.1.1.1245
CNTV2RegisterExpert Class Reference

I provide "one-stop shopping" for information about registers and their values. More...

#include <ntv2registerexpert.h>

Static Public Member Functions

static std::string GetDisplayName (const uint32_t inRegNum)
 
static std::string GetDisplayValue (const uint32_t inRegNum, const uint32_t inRegValue, const NTV2DeviceID inDeviceID=DEVICE_ID_NOTFOUND)
 
static bool IsRegisterInClass (const uint32_t inRegNum, const std::string &inClassName)
 
static bool IsReadOnly (const uint32_t inRegNum)
 
static bool IsWriteOnly (const uint32_t inRegNum)
 
static NTV2StringSet GetAllRegisterClasses (void)
 
static NTV2StringSet GetRegisterClasses (const uint32_t inRegNum, const bool inRemovePrefix=false)
 
static NTV2RegNumSet GetRegistersForClass (const std::string &inClassName)
 
static NTV2RegNumSet GetRegistersForChannel (const NTV2Channel inChannel)
 
static NTV2RegNumSet GetRegistersForDevice (const NTV2DeviceID inDeviceID, const int inOtherRegsToInclude=0)
 
static NTV2RegNumSet GetRegistersWithName (const std::string &inName, const int inSearchStyle=EXACTMATCH)
 
static NTV2InputCrosspointID GetInputCrosspointID (const uint32_t inXptRegNum, const uint32_t inMaskIndex)
 
static bool GetCrosspointSelectGroupRegisterInfo (const NTV2InputCrosspointID inInputXpt, uint32_t &outXptRegNum, uint32_t &outMaskIndex)
 Answers with the crosspoint select register and mask information for a given widget input. More...
 
static bool IsAllocated (void)
 
static bool Allocate (void)
 Explicitly allocates the Register Expert singleton. More...
 
static bool Deallocate (void)
 Explicitly deallocates the Register Expert singleton. More...
 

Static Public Attributes

static const int CONTAINS = 0
 The name must contain the search string (see CNTV2RegisterExpert::GetRegistersWithName) More...
 
static const int STARTSWITH = 1
 The name must start with the search string (see CNTV2RegisterExpert::GetRegistersWithName) More...
 
static const int ENDSWITH = 2
 The name must end with the search string (see CNTV2RegisterExpert::GetRegistersWithName) More...
 
static const int EXACTMATCH = 3
 The name must exactly match the search string (see CNTV2RegisterExpert::GetRegistersWithName) More...
 

Detailed Description

I provide "one-stop shopping" for information about registers and their values.

Bug:
This class currently excludes bank-selected registers, so support logs for KONA IP and Io IP will be incomplete. This will be addressed in a future SDK.

Definition at line 87 of file ntv2registerexpert.h.

Member Function Documentation

◆ Allocate()

bool CNTV2RegisterExpert::Allocate ( void  )
static

Explicitly allocates the Register Expert singleton.

Returns
True if successful; otherwise false.
Note
Normally, there is no need to call this function, as the RegisterExpert singleton is automatically allocated.

Definition at line 4591 of file ntv2registerexpert.cpp.

◆ Deallocate()

bool CNTV2RegisterExpert::Deallocate ( void  )
static

Explicitly deallocates the Register Expert singleton.

Returns
True if successful; otherwise false.
Note
Normally, there is no need to call this function, as the RegisterExpert singleton is automatically deallocated.

Definition at line 4605 of file ntv2registerexpert.cpp.

◆ GetAllRegisterClasses()

NTV2StringSet CNTV2RegisterExpert::GetAllRegisterClasses ( void  )
static
Returns
A set of strings containing the names of all known register classes.

Definition at line 4643 of file ntv2registerexpert.cpp.

◆ GetCrosspointSelectGroupRegisterInfo()

bool CNTV2RegisterExpert::GetCrosspointSelectGroupRegisterInfo ( const NTV2InputCrosspointID  inInputXpt,
uint32_t &  outXptRegNum,
uint32_t &  outMaskIndex 
)
static

Answers with the crosspoint select register and mask information for a given widget input.

Parameters
[in]inInputXptSpecifies the NTV2InputCrosspointID of interest.
[out]outXptRegNumReceives the crosspoint select group register number.
[out]outMaskIndexReceives the mask index (where 0=0x000000FF, 1=0x0000FF00, 2=0x00FF0000, 3=0xFF000000).
Returns
True if successful; otherwise false.

Definition at line 4692 of file ntv2registerexpert.cpp.

◆ GetDisplayName()

string CNTV2RegisterExpert::GetDisplayName ( const uint32_t  inRegNum)
static
Parameters
[in]inRegNumSpecifies the register number.
Returns
A string that contains the name of the register (or empty if unknown).

Definition at line 4612 of file ntv2registerexpert.cpp.

◆ GetDisplayValue()

string CNTV2RegisterExpert::GetDisplayValue ( const uint32_t  inRegNum,
const uint32_t  inRegValue,
const NTV2DeviceID  inDeviceID = DEVICE_ID_NOTFOUND 
)
static
Parameters
[in]inRegNumSpecifies the register number.
[in]inRegValueSpecifies the 32-bit register value.
[in]inDeviceIDOptionally specifies an NTV2DeviceID. Defaults to DEVICE_ID_NOTFOUND.
Returns
A string that contains the human-readable rendering of the value of the given register (or empty if unknown).

Definition at line 4629 of file ntv2registerexpert.cpp.

◆ GetInputCrosspointID()

NTV2InputCrosspointID CNTV2RegisterExpert::GetInputCrosspointID ( const uint32_t  inXptRegNum,
const uint32_t  inMaskIndex 
)
static
Parameters
[in]inXptRegNumSpecifies the crosspoint select group register number. Note that it only makes sense to pass register numbers having names that start with "kRegXptSelectGroup".
[in]inMaskIndexSpecifies the mask index, an unsigned value that must be less than 4. (0 specifies the least significant byte of the crosspoint register value, 3 specifies the most significant byte, etc.)
Returns
The NTV2InputCrosspointID of the widget input crosspoint associated with the given "Xpt" register and mask index, or NTV2_INPUT_CROSSPOINT_INVALID if there isn't one.

Definition at line 4685 of file ntv2registerexpert.cpp.

◆ GetRegisterClasses()

NTV2StringSet CNTV2RegisterExpert::GetRegisterClasses ( const uint32_t  inRegNum,
const bool  inRemovePrefix = false 
)
static
Returns
A set of strings containing the names of all register classes the given register belongs to.

Definition at line 4650 of file ntv2registerexpert.cpp.

◆ GetRegistersForChannel()

NTV2RegNumSet CNTV2RegisterExpert::GetRegistersForChannel ( const NTV2Channel  inChannel)
static
Parameters
[in]inChannelSpecifies a valid NTV2Channel.
Returns
A set of register numbers that are associated with the given NTV2Channel (class kRegClass_ChannelN). Will be empty if an invalid NTV2Channel is specified.

Definition at line 4664 of file ntv2registerexpert.cpp.

◆ GetRegistersForClass()

NTV2RegNumSet CNTV2RegisterExpert::GetRegistersForClass ( const std::string &  inClassName)
static
Parameters
[in]inClassNameSpecifies the register class.
Returns
A set of register numbers that belong to the specified class. Will be empty if none found.

Definition at line 4657 of file ntv2registerexpert.cpp.

◆ GetRegistersForDevice()

NTV2RegNumSet CNTV2RegisterExpert::GetRegistersForDevice ( const NTV2DeviceID  inDeviceID,
const int  inOtherRegsToInclude = 0 
)
static
Parameters
[in]inDeviceIDSpecifies a valid NTV2DeviceID.
[in]inOtherRegsToIncludeA bit mask of other registers to include (or zero, the default, for no others). Specify kIncludeOtherRegs_VRegs to include virtual regs; Specify kIncludeOtherRegs_XptMap to include crosspoint mapping regs.
Returns
A set of register numbers that are legal for the device having the given NTV2DeviceID. Will be empty if an invalid NTV2DeviceID is specified.

Definition at line 4671 of file ntv2registerexpert.cpp.

◆ GetRegistersWithName()

NTV2RegNumSet CNTV2RegisterExpert::GetRegistersWithName ( const std::string &  inName,
const int  inSearchStyle = EXACTMATCH 
)
static
Parameters
[in]inNameSpecifies a non-empty string that contains all or part of a register name.
[in]inSearchStyleSpecifies the search style. Must be EXACTMATCH (the default), CONTAINS, STARTSWITH or ENDSWITH.
Returns
A set of register numbers that match all or part of the given name. Empty if none match.
Note
All searching is performed case-insensitively.

Definition at line 4678 of file ntv2registerexpert.cpp.

◆ IsAllocated()

bool CNTV2RegisterExpert::IsAllocated ( void  )
static
Returns
True if the Register Expert singleton has been allocated/created; otherwise false.

Definition at line 4598 of file ntv2registerexpert.cpp.

◆ IsReadOnly()

static bool CNTV2RegisterExpert::IsReadOnly ( const uint32_t  inRegNum)
inlinestatic
Parameters
[in]inRegNumSpecifies the register number.
Returns
True if the register is read-only (i.e., it cannot be written); otherwise false.

Definition at line 116 of file ntv2registerexpert.h.

◆ IsRegisterInClass()

bool CNTV2RegisterExpert::IsRegisterInClass ( const uint32_t  inRegNum,
const std::string &  inClassName 
)
static
Parameters
[in]inRegNumSpecifies the register number.
[in]inClassNameSpecifies the class name.
Returns
True if the register is a member of the class; otherwise false.

Definition at line 4636 of file ntv2registerexpert.cpp.

◆ IsWriteOnly()

static bool CNTV2RegisterExpert::IsWriteOnly ( const uint32_t  inRegNum)
inlinestatic
Parameters
[in]inRegNumSpecifies the register number.
Returns
True if the register is write-only (i.e., it cannot be read); otherwise false.

Definition at line 122 of file ntv2registerexpert.h.

Member Data Documentation

◆ CONTAINS

const int CNTV2RegisterExpert::CONTAINS = 0
static

The name must contain the search string (see CNTV2RegisterExpert::GetRegistersWithName)

Definition at line 187 of file ntv2registerexpert.h.

◆ ENDSWITH

const int CNTV2RegisterExpert::ENDSWITH = 2
static

The name must end with the search string (see CNTV2RegisterExpert::GetRegistersWithName)

Definition at line 189 of file ntv2registerexpert.h.

◆ EXACTMATCH

const int CNTV2RegisterExpert::EXACTMATCH = 3
static

The name must exactly match the search string (see CNTV2RegisterExpert::GetRegistersWithName)

Definition at line 190 of file ntv2registerexpert.h.

◆ STARTSWITH

const int CNTV2RegisterExpert::STARTSWITH = 1
static

The name must start with the search string (see CNTV2RegisterExpert::GetRegistersWithName)

Definition at line 188 of file ntv2registerexpert.h.


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