#include <DataBuffers.h>
Inheritance diagram for TGraphicBuffer:
Public Member Functions | |
TGraphicBuffer (const DWORD &size, const DWORD &itemSize) | |
Constructor. | |
~TGraphicBuffer (void) | |
Destructor. | |
void | Clone (TGraphicBuffer **buffer) const |
Create copy of this buffer. | |
void | Set (const TGraphicBuffer &buffer) |
Copy data from another buffer to this buffer. | |
void | Clone (const DWORD &items, TGraphicBuffer **buffer) const |
Create copy of specified number of items from this buffer. | |
void | Set (const TGraphicBuffer &buffer, const DWORD &items) |
Copy data from another buffer to this buffer. | |
void | AddBuffer (const TGraphicBuffer &buffer) |
Adds data from another buffer at end of this buffer. | |
void | AddBuffer (const TGraphicBuffer &buffer, const DWORD &items) |
Adds data from another buffer at end of this buffer. | |
void * | GetDataAtItem (const DWORD &item) |
Returns pointer to specified item. | |
const void * | GetDataAtItem (const DWORD &item) const |
Returns pointer to specified item. | |
void * | GetData (void) |
Returns pointer to data stored inside buffer. | |
const void * | GetData (void) const |
Returns pointer to data stored inside buffer. | |
DWORD | GetSize (void) const |
Returns size of data stored inside buffer, in bytes. | |
DWORD | GetItemSize (void) const |
Returns size of one item in bytes. | |
DWORD | GetItemsCount (void) const |
Returns number of items stored inside buffer. |
This buffer cannot be used for rendering, but has similar functionality like buffer from renderer.
Data stored inside buffer has no type - they are stored in raw format. This enables copy data directly to/from HW buffers. Nevertheless each buffer has information about size of one data item. This is required for some routines which mainpulate with data.
Definition at line 28 of file DataBuffers.h.
|
Constructor. Creates buffer with number of items (== SIZE) and with size of one item equal to ITEMSIZE If parameters are wrong, at least buffer with 1 item of size 1 byte is created.
Definition at line 35 of file DataBuffers.cpp. |
|
Destructor.
Definition at line 60 of file DataBuffers.cpp. |
|
Adds data from another buffer at end of this buffer. Added buffer must have the same ITEM SIZE as this buffer. You must specified number of items from second buffer which will be added. If this number is great than number of available items in BUFFER then maximum possible count of items will be added.
Definition at line 164 of file DataBuffers.cpp. References DBGTEXTF, and GetItemSize(). Here is the call graph for this function: ![]() |
|
Adds data from another buffer at end of this buffer. Added buffer must have the same ITEM SIZE as this buffer.
Definition at line 148 of file DataBuffers.cpp. References GetItemsCount(). Here is the call graph for this function: ![]() |
|
Create copy of specified number of items from this buffer. Number of copied items must be always at least 1.
Definition at line 107 of file DataBuffers.cpp. References Set(). Here is the call graph for this function: ![]() |
|
Create copy of this buffer.
Definition at line 72 of file DataBuffers.cpp. References Set(). Here is the call graph for this function: ![]() |
|
Returns pointer to data stored inside buffer.
Definition at line 64 of file DataBuffers.h. |
|
Returns pointer to data stored inside buffer.
Definition at line 60 of file DataBuffers.h. |
|
Returns pointer to specified item. Item index must valid, otherwise NULL is returned.
Definition at line 215 of file DataBuffers.cpp. References DBGTEXTF. |
|
Returns pointer to specified item. Item index must valid, otherwise NULL is returned.
Definition at line 197 of file DataBuffers.cpp. References DBGTEXTF. Referenced by NSMeshes::TMeshCreator::CreateBox_XYZ_COLOR(), NSMeshes::TMeshCreator::CreateBox_XYZ_NXNYNZ_COLOR(), and NSMeshes::TMeshCreator::CreateBox_XYZ_TUTV(). |
|
Returns number of items stored inside buffer.
Definition at line 76 of file DataBuffers.h. Referenced by AddBuffer(). |
|
Returns size of one item in bytes.
Definition at line 72 of file DataBuffers.h. Referenced by AddBuffer(). |
|
Returns size of data stored inside buffer, in bytes.
Definition at line 68 of file DataBuffers.h. |
|
Copy data from another buffer to this buffer. Only specified number of items will be copy. Number of copied items must be always at least 1. After this new buffer is exactly the same as original buffer.
Definition at line 121 of file DataBuffers.cpp. References DBGTEXTF, m_data, and m_item_size. |
|
Copy data from another buffer to this buffer. After this new buffer is exactly the same as original buffer.
Definition at line 86 of file DataBuffers.cpp. References m_data, m_item_size, m_number_items, and m_size. Referenced by Clone(). |