# Home    # nevrax.com   
Nevrax
Nevrax.org
#News
#Mailing-list
#Documentation
#CVS
#Bugs
#License
Docs
 
Documentation  
Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages   Search  

NL3D::CVertexArrayRange Class Reference

Work only if ARRAY_RANGE_NV is enabled. More...

#include <driver_opengl.h>

List of all members.

Public Methods

 CVertexArrayRange ()
void init (CDriverGL *drv)
bool allocated () const
bool allocate (uint32 size, IDriver::TVBHardType vbType)
 allocate a vertex array sapce. false if error. must free before re-allocate. More...

void free ()
 free this space. More...

void enable ()
 active this VertexArrayRange as the current vertex array range used. no-op if already setup. More...

void disable ()
 disable this VertexArrayRange. _Driver->_CurrentVertexArrayRange= NULL;. More...

void * allocateVB (uint32 size)
 Allocate a small subset of the memory. NULL if not enough mem. More...

void freeVB (void *ptr)
 free a VB allocated with allocateVB. No-op if NULL. More...


Private Attributes

CDriverGL_Driver
void * _VertexArrayPtr
uint32 _VertexArraySize
NLMISC::CHeapMemory _HeapMemory


Detailed Description

Work only if ARRAY_RANGE_NV is enabled.

else, only call to ctor/dtor/free() is valid. any call to allocateVB() will return NULL.

Definition at line 168 of file driver_opengl.h.


Constructor & Destructor Documentation

NL3D::CVertexArrayRange::CVertexArrayRange   [inline]
 

Definition at line 171 of file driver_opengl.h.

References _Driver, _VertexArrayPtr, and _VertexArraySize.


Member Function Documentation

bool NL3D::CVertexArrayRange::allocate uint32    size,
IDriver::TVBHardType    vbType
 

allocate a vertex array sapce. false if error. must free before re-allocate.

Definition at line 931 of file driver_opengl_vertex.cpp.

References _HeapMemory, _VertexArrayPtr, _VertexArraySize, NLMISC::CHeapMemory::initHeap, nlassert, size, and uint32.

bool NL3D::CVertexArrayRange::allocated   const [inline]
 

Definition at line 184 of file driver_opengl.h.

References _VertexArrayPtr.

void * NL3D::CVertexArrayRange::allocateVB uint32    size
 

Allocate a small subset of the memory. NULL if not enough mem.

Definition at line 1012 of file driver_opengl_vertex.cpp.

References _HeapMemory, NLMISC::CHeapMemory::allocate, size, and uint32.

void NL3D::CVertexArrayRange::disable  
 

disable this VertexArrayRange. _Driver->_CurrentVertexArrayRange= NULL;.

Definition at line 999 of file driver_opengl_vertex.cpp.

References _Driver, and nglVertexArrayRangeNV.

void NL3D::CVertexArrayRange::enable  
 

active this VertexArrayRange as the current vertex array range used. no-op if already setup.

Definition at line 986 of file driver_opengl_vertex.cpp.

References _Driver, _VertexArrayPtr, _VertexArraySize, and nglVertexArrayRangeNV.

void NL3D::CVertexArrayRange::free  
 

free this space.

Definition at line 965 of file driver_opengl_vertex.cpp.

References _HeapMemory, _VertexArrayPtr, and NLMISC::CHeapMemory::reset.

void NL3D::CVertexArrayRange::freeVB void *    ptr
 

free a VB allocated with allocateVB. No-op if NULL.

Definition at line 1019 of file driver_opengl_vertex.cpp.

References _HeapMemory, and NLMISC::CHeapMemory::free.

void NL3D::CVertexArrayRange::init CDriverGL   drv [inline]
 

Definition at line 179 of file driver_opengl.h.

References _Driver.


Member Data Documentation

CDriverGL* NL3D::CVertexArrayRange::_Driver [private]
 

Definition at line 207 of file driver_opengl.h.

Referenced by CVertexArrayRange, disable, enable, and init.

NLMISC::CHeapMemory NL3D::CVertexArrayRange::_HeapMemory [private]
 

Definition at line 212 of file driver_opengl.h.

Referenced by allocate, allocateVB, free, and freeVB.

void* NL3D::CVertexArrayRange::_VertexArrayPtr [private]
 

Definition at line 208 of file driver_opengl.h.

Referenced by allocate, allocated, CVertexArrayRange, enable, and free.

uint32 NL3D::CVertexArrayRange::_VertexArraySize [private]
 

Definition at line 209 of file driver_opengl.h.

Referenced by allocate, CVertexArrayRange, and enable.


The documentation for this class was generated from the following files: