AJA NTV2 SDK
17.1.3.1410
NTV2 SDK 17.1.3.1410
|
I am a thread-safe queue of caption messages. Internally, I maintain two queues: one for high-priority messages, another for low-priority ones. Calling CNTV2Caption608MessageQueue::GetNextCaptionMessage will never return a low-priority message if a high-priority message is waiting to go out. More...
#include <ntv2caption608messagequeue.h>
Public Member Functions | |
CNTV2Caption608MessageQueue () | |
virtual | ~CNTV2Caption608MessageQueue () |
virtual CNTV2Caption608MessagePtr | GetNextCaptionMessage (void) |
Dequeues and returns my front-most caption message. If no messages are waiting to go out, I'll return a NULL (empty) CNTV2Caption608MessagePtr. More... | |
virtual bool | EnqueueCaptionMessage (CNTV2Caption608MessagePtr inMsg) |
Enqueues the given caption message. High-priority messages go ahead of any/all low-priority messages. More... | |
virtual size_t | Flush (void) |
Empties me. More... | |
virtual size_t | Flush (const NTV2Line21Channel inChannel) |
Flushes all of my messages that are associated with the given caption channel. More... | |
virtual std::ostream & | Print (std::ostream &inOutStream, const bool inDumpMessages=true) const |
Prints a human-readable representation of me to the given output stream in oldest-to-newest order. More... | |
virtual size_t | GetQueuedMessageCount (void) const |
Answers with my current depth. More... | |
virtual size_t | GetQueuedMessageCount (const NTV2Line21Channel inChannel) const |
Returns the number of messages queued for the given caption channel. More... | |
virtual size_t | GetQueuedByteCount (void) const |
Answers with the total number of bytes (including command bytes) that I currently have queued. More... | |
virtual size_t | GetQueuedByteCount (const NTV2Line21Channel inChannel) const |
Returns the number of message bytes queued for the given caption channel. More... | |
virtual size_t | GetEnqueueByteTally (void) const |
Returns the total number of bytes (including command bytes) that have been enqueued onto me since I was instantiated. More... | |
virtual size_t | GetDequeueByteTally (void) const |
Returns the total number of bytes (including command bytes) that have been dequeued from me since I was instantiated. More... | |
virtual size_t | GetEnqueueMessageTally (void) const |
Returns the total number of messages that have been enqueued onto me since I was instantiated. More... | |
virtual size_t | GetDequeueMessageTally (void) const |
Returns the total number of messages that have been dequeued from me since I was instantiated. More... | |
virtual size_t | GetEnqueueByteTally (const NTV2Line21Channel inChannel) const |
Returns the total number of bytes (including command bytes) that have been enqueued onto me for the given caption channel since I was instantiated. More... | |
virtual size_t | GetDequeueByteTally (const NTV2Line21Channel inChannel) const |
Returns the total number of bytes (including command bytes) that have been dequeued from me for the given caption channel since I was instantiated. More... | |
virtual size_t | GetEnqueueMessageTally (const NTV2Line21Channel inChannel) const |
Returns the total number of messages that have been enqueued onto me for the given caption channel since I was instantiated. More... | |
virtual size_t | GetDequeueMessageTally (const NTV2Line21Channel inChannel) const |
Returns the total number of messages that have been dequeued from me for the given caption channel since I was instantiated. More... | |
virtual size_t | GetHighestQueueDepth (void) const |
Returns the highest queue depth – i.e., the maximum number of messages I held in either of my queues – since I was instantiated. More... | |
Public Member Functions inherited from CNTV2CaptionLogConfig | |
CNTV2CaptionLogConfig (const std::string inLogLabel=std::string()) | |
Default constructor. More... | |
virtual | ~CNTV2CaptionLogConfig () |
virtual NTV2CaptionLogMask | SetLogMask (const NTV2CaptionLogMask inLogMask) |
Specifies what, if any, debug information I will write to my log stream. More... | |
virtual NTV2CaptionLogMask | GetLogMask (void) const |
Answers with my current caption logging bit mask. More... | |
virtual bool | TestLogMask (const NTV2CaptionLogMask inLogMask, const bool inExact=false) const |
Answers true if the given log mask bits are set in my current log mask. More... | |
virtual void | SetLogLabel (const std::string &inNewLabel) |
Specifies my logging label. More... | |
virtual void | AppendToLogLabel (const std::string &inString) |
Appends the given string to my current log label. More... | |
virtual const std::string & | GetLogLabel (void) const |
Answers with my current logging label. More... | |
virtual void | SetLogStream (std::ostream &inOutputStream) |
virtual std::ostream & | LogIf (const NTV2CaptionLogMask inLogMask) const |
virtual std::ostream & | Log (void) const |
Additional Inherited Members | |
Static Public Member Functions inherited from CNTV2CaptionLogConfig | |
static std::ostream & | DumpMemory (const void *pInStartAddress, const size_t inByteCount, std::ostream &inOutputStream=std::cout, const size_t inRadix=16, const size_t inBytesPerGroup=4, const size_t inGroupsPerLine=8, const size_t inAddressRadix=16, const bool inShowAscii=true, const size_t inAddrOffset=0) |
Dumps a contiguous chunk of memory in hex, octal, decimal, with or without ascii, to the given output stream. More... | |
static std::string | HexDump32Bytes (const void *pInStartAddress, const size_t inByteCount, const size_t inLimitBytes=32) |
static std::ostream & | DumpYBytes_2vuy (const UByte *pInVideoLine, std::ostream &inOutputStream, const unsigned inFromPixel=0, const unsigned inToPixel=719, const bool inShowRuler=true, const unsigned inHiliteRangeFrom=9999, const unsigned inHiliteRangeTo=9999) |
Dumps the luma values in hexadecimal from the given line of '2vuy' video to the given output stream. More... | |
static std::ostream & | DumpYBytes_2vuy (const std::vector< uint8_t > &inVideoLine, std::ostream &inOutputStream, const size_t inFromPixel=0, const size_t inToPixel=719, const bool inShowRuler=true, const size_t inHiliteRangeFrom=9999, const size_t inHiliteRangeTo=9999) |
Dumps the luma values in hexadecimal from the given line of '2vuy' video to the given output stream. More... | |
static std::string | GetSeverityLabel (const unsigned inSeverity) |
Protected Attributes inherited from CNTV2CaptionLogConfig | |
NTV2CaptionLogMask | mLogMask |
Determines what messages are logged. More... | |
std::string | mLogLabel |
My debug label. More... | |
void * | mpLabelLock |
Protects my debug label from simultaneous access by more than one thread. More... | |
I am a thread-safe queue of caption messages. Internally, I maintain two queues: one for high-priority messages, another for low-priority ones. Calling CNTV2Caption608MessageQueue::GetNextCaptionMessage will never return a low-priority message if a high-priority message is waiting to go out.
Definition at line 20 of file ntv2caption608messagequeue.h.
CNTV2Caption608MessageQueue::CNTV2Caption608MessageQueue | ( | ) |
|
virtual |
|
virtual |
Enqueues the given caption message. High-priority messages go ahead of any/all low-priority messages.
[in] | inMsg | The message to be enqueued. |
|
virtual |
Flushes all of my messages that are associated with the given caption channel.
[in] | inChannel | The caption channel whose messages are to be removed. |
|
virtual |
Empties me.
|
virtual |
Returns the total number of bytes (including command bytes) that have been dequeued from me for the given caption channel since I was instantiated.
|
virtual |
Returns the total number of bytes (including command bytes) that have been dequeued from me since I was instantiated.
|
virtual |
Returns the total number of messages that have been dequeued from me for the given caption channel since I was instantiated.
|
virtual |
Returns the total number of messages that have been dequeued from me since I was instantiated.
|
virtual |
Returns the total number of bytes (including command bytes) that have been enqueued onto me for the given caption channel since I was instantiated.
|
virtual |
Returns the total number of bytes (including command bytes) that have been enqueued onto me since I was instantiated.
|
virtual |
Returns the total number of messages that have been enqueued onto me for the given caption channel since I was instantiated.
|
virtual |
Returns the total number of messages that have been enqueued onto me since I was instantiated.
|
inlinevirtual |
Returns the highest queue depth – i.e., the maximum number of messages I held in either of my queues – since I was instantiated.
Definition at line 138 of file ntv2caption608messagequeue.h.
|
virtual |
Dequeues and returns my front-most caption message. If no messages are waiting to go out, I'll return a NULL (empty) CNTV2Caption608MessagePtr.
|
virtual |
Returns the number of message bytes queued for the given caption channel.
[in] | inChannel | Specifies the caption channel of interest. |
|
virtual |
Answers with the total number of bytes (including command bytes) that I currently have queued.
|
virtual |
Returns the number of messages queued for the given caption channel.
[in] | inChannel | Specifies the caption channel of interest. |
|
virtual |
Answers with my current depth.
|
virtual |
Prints a human-readable representation of me to the given output stream in oldest-to-newest order.
inOutStream | Specifies the output stream to receive my human-readable representation. | |
[in] | inDumpMessages | If true, also dump my messages; otherwise don't dump my messages. Defaults to true. |