General Structures > QUEUE |
A data structure specifying a circular queue. A Pegasus operation has an input or Get, queue and an output, or Put, queue. See the Queue Management section in the PICTools and AIMTools Programmer's Guide for additional information about using this structure with an ordinary linear buffer. See also Appendix 1 in this document for a description of how to use the input and output buffers as circular queues.
Copy Code | |
---|---|
typedef struct {
BYTE PICHUGE* FrontEnd;
BYTE PICHUGE* Start;
BYTE PICHUGE* Front;
BYTE PICHUGE* Rear;
BYTE PICHUGE* End;
BYTE PICHUGE* RearEnd;
DWORD QFlags;
} QUEUE; |
Name | Description | ||||||||||||||
FrontEnd |
Reserved for Pegasus. | ||||||||||||||
Start |
Points to the first byte of the buffer being used for the queue. | ||||||||||||||
Front Rear |
If Front equals Rear, then the queue is empty. If the Q_REVERSE flag is clear in QFlags then the queue is a forward queue and Front points to the next byte of valid data to be consumed. Valid data extends from Front forward (towards End) to the byte preceding Rear. If Rear is less than Front, then the queue data has wrapped around from End to Start. If the Q_REVERSE flag is set in QFlags, then the queue is a reversed queue and Front points to the first byte following the next byte of valid data to be consumed. Valid data extends from that next byte of valid data back (towards Start) to the byte pointed to by Rear. If Rear is greater than Front, then the queue data has wrapped around from Start to End. | ||||||||||||||
End |
Points to the first byte following the buffer being used for the queue. | ||||||||||||||
RearEnd |
Reserved for Pegasus. | ||||||||||||||
QFlags |
|