28 #ifndef __D3D10HARDWAREVERTEXBUFFER_H__
29 #define __D3D10HARDWAREVERTEXBUFFER_H__
53 void readData(
size_t offset,
size_t length,
void* pDest);
54 void writeData(
size_t offset,
size_t length,
const void* pSource,
55 bool discardWholeBuffer =
false);
58 size_t dstOffset,
size_t length,
bool discardWholeBuffer =
false);
~D3D10HardwareVertexBuffer()
void * lock(size_t offset, size_t length, LockOptions options)
Lock the buffer for (potentially) reading / writing.
D3D10HardwareVertexBuffer(HardwareBufferManagerBase *mgr, size_t vertexSize, size_t numVertices, HardwareBuffer::Usage usage, D3D10Device &device, bool useSystemMem, bool useShadowBuffer)
void unlock(void)
Releases the lock on this buffer.
bool releaseIfDefaultPool(void)
For dealing with lost devices - release the resource if in the default pool.
Specialisation of HardwareVertexBuffer for D3D10.
LockOptions
Locking options.
Base definition of a hardware buffer manager.
Usage
Enums describing buffer usage; not mutually exclusive.
void readData(size_t offset, size_t length, void *pDest)
Reads data from the buffer and places it in the memory pointed to by pDest.
void copyData(HardwareBuffer &srcBuffer, size_t srcOffset, size_t dstOffset, size_t length, bool discardWholeBuffer=false)
Copy data from another buffer into this one.
void * lockImpl(size_t offset, size_t length, LockOptions options)
Internal implementation of lock()
void unlockImpl(void)
Internal implementation of unlock()
bool recreateIfDefaultPool(D3D10Device &device)
For dealing with lost devices - recreate the resource if in the default pool.
bool isLocked(void) const
D3D10HardwareBuffer * mBufferImpl
Abstract class defining common features of hardware buffers.
Base implementation of a D3D10 buffer, dealing with all the common aspects.
void writeData(size_t offset, size_t length, const void *pSource, bool discardWholeBuffer=false)
Writes data to the buffer from an area of system memory; note that you must ensure that your buffer i...
Specialisation of HardwareBuffer for a vertex buffer.
ID3D10Buffer * getD3DVertexBuffer(void) const
Get the D3D-specific vertex buffer.