CrystalSpace

Public API Reference

Main Page | Modules | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages

iRenderBuffer Struct Reference
[3D]

This is a general buffer. More...

#include <ivideo/rndbuf.h>

Inheritance diagram for iRenderBuffer:

iBase csRenderBuffer List of all members.

Public Member Functions

virtual void * Lock (csRenderBufferLockType lockType)=0
 Lock the buffer to allow writing and give us a pointer to the data.
virtual void Release ()=0
 Releases the buffer. After this all writing to the buffer is illegal.
virtual void CopyInto (const void *data, size_t elementCount, size_t elemOffset=0)=0
 Copy data to the render buffer.
virtual int GetComponentCount () const =0
 Gets the number of components per element.
virtual csRenderBufferComponentType GetComponentType () const =0
 Gets the component type (float, int, etc).
virtual csRenderBufferType GetBufferType () const =0
 Get type of buffer (static/dynamic).
virtual size_t GetSize () const =0
 Get the size of the buffer (in bytes).
virtual size_t GetStride () const =0
 Get the stride of the buffer (in bytes).
virtual size_t GetElementDistance () const =0
 Get the distance between two elements (in bytes, includes stride).
virtual size_t GetOffset () const =0
 Get the offset of the buffer (in bytes).
virtual uint GetVersion ()=0
 Get version.
virtual iRenderBufferGetMasterBuffer () const =0
 Get the master buffer in case this is an interleaved buffer.
virtual bool IsIndexBuffer () const =0
 Whether the buffer is an index buffer.
virtual size_t GetRangeStart () const =0
 The lowest index contained in this buffer, only valid for index buffers.
virtual size_t GetRangeEnd () const =0
 The highest index contained in this buffer, only valid for index buffers.
virtual size_t GetElementCount () const =0
 Number of elements in a buffer.

Detailed Description

This is a general buffer.

Main creators of instances implementing this interface:

See also:
csRenderBuffer

Definition at line 110 of file rndbuf.h.


Member Function Documentation

virtual void iRenderBuffer::CopyInto const void *  data,
size_t  elementCount,
size_t  elemOffset = 0
[pure virtual]
 

Copy data to the render buffer.

Remarks:
Does not work with interleaved buffer, copy to master buffer instead.

Implemented in csRenderBuffer.

virtual csRenderBufferType iRenderBuffer::GetBufferType  )  const [pure virtual]
 

Get type of buffer (static/dynamic).

Implemented in csRenderBuffer.

virtual int iRenderBuffer::GetComponentCount  )  const [pure virtual]
 

Gets the number of components per element.

Implemented in csRenderBuffer.

virtual csRenderBufferComponentType iRenderBuffer::GetComponentType  )  const [pure virtual]
 

Gets the component type (float, int, etc).

Implemented in csRenderBuffer.

virtual size_t iRenderBuffer::GetElementCount  )  const [pure virtual]
 

Number of elements in a buffer.

Implemented in csRenderBuffer.

virtual size_t iRenderBuffer::GetElementDistance  )  const [pure virtual]
 

Get the distance between two elements (in bytes, includes stride).

Implemented in csRenderBuffer.

virtual iRenderBuffer* iRenderBuffer::GetMasterBuffer  )  const [pure virtual]
 

Get the master buffer in case this is an interleaved buffer.

The master buffer is the buffer that actually holds the data; while it can be used to retrieve or set data, it must not be used for actual rendering. Use the interleaved buffers instead.

Implemented in csRenderBuffer.

virtual size_t iRenderBuffer::GetOffset  )  const [pure virtual]
 

Get the offset of the buffer (in bytes).

Implemented in csRenderBuffer.

virtual size_t iRenderBuffer::GetRangeEnd  )  const [pure virtual]
 

The highest index contained in this buffer, only valid for index buffers.

Implemented in csRenderBuffer.

virtual size_t iRenderBuffer::GetRangeStart  )  const [pure virtual]
 

The lowest index contained in this buffer, only valid for index buffers.

Implemented in csRenderBuffer.

virtual size_t iRenderBuffer::GetSize  )  const [pure virtual]
 

Get the size of the buffer (in bytes).

Implemented in csRenderBuffer.

virtual size_t iRenderBuffer::GetStride  )  const [pure virtual]
 

Get the stride of the buffer (in bytes).

Implemented in csRenderBuffer.

virtual uint iRenderBuffer::GetVersion  )  [pure virtual]
 

Get version.

Implemented in csRenderBuffer.

virtual bool iRenderBuffer::IsIndexBuffer  )  const [pure virtual]
 

Whether the buffer is an index buffer.

Implemented in csRenderBuffer.

virtual void* iRenderBuffer::Lock csRenderBufferLockType  lockType  )  [pure virtual]
 

Lock the buffer to allow writing and give us a pointer to the data.

The pointer will be (void*)-1 if there was some error.

Parameters:
lockType The type of lock desired.

Implemented in csRenderBuffer.

virtual void iRenderBuffer::Release  )  [pure virtual]
 

Releases the buffer. After this all writing to the buffer is illegal.

Implemented in csRenderBuffer.


The documentation for this struct was generated from the following file:
Generated for Crystal Space by doxygen 1.3.9.1