25 #ifndef OPENSUBDIV3_OSD_CUDA_VERTEX_BUFFER_H 
   26 #define OPENSUBDIV3_OSD_CUDA_VERTEX_BUFFER_H 
   28 #include "../version.h" 
   32 namespace OpenSubdiv {
 
   33 namespace OPENSUBDIV_VERSION {
 
   47                                      void *deviceContext = NULL);
 
   54     void UpdateData(
const float *src, 
int startVertex, 
int numVertices,
 
   55                     void *deviceContext=NULL);
 
   84 using namespace OPENSUBDIV_VERSION;
 
   88 #endif  // OPENSUBDIV3_OSD_CUDA_VERTEX_BUFFER_H 
Concrete vertex buffer class for Cuda subdivision. 
static CudaVertexBuffer * Create(int numElements, int numVertices, void *deviceContext=NULL)
Creator. Returns NULL if error. 
void UpdateData(const float *src, int startVertex, int numVertices, void *deviceContext=NULL)
int GetNumVertices() const 
Returns how many vertices allocated in this vertex buffer. 
CudaVertexBuffer(int numElements, int numVertices)
Constructor. 
int GetNumElements() const 
Returns how many elements defined in this vertex buffer. 
float * BindCudaBuffer()
Returns cuda memory. 
~CudaVertexBuffer()
Destructor.