vbuffer_mixin Class Template Reference

#include <vbuffer.hpp>

Inheritance diagram for vbuffer_mixin:

Inheritance graph
[legend]
Collaboration diagram for vbuffer_mixin:

Collaboration graph
[legend]

List of all members.


Detailed Description

template<typename T>
class gsgl::platform::vbuffer_mixin< T >

Mixes in an array of the appropriate data type.

Definition at line 99 of file vbuffer.hpp.


Public Member Functions

void append (const T &t)
void bind ()
 Binds the buffer object for use with OpenGL.
gsgl::data::simple_array< T > & get_buffer ()
void load ()
 Loads the buffer object into the video card.
T & operator[] (const gsgl::index_t &i)
const T & operator[] (const gsgl::index_t &i) const
gsgl::index_t size () const
void unbind ()
 Unbinds the buffer object for use with OpenGL.
void unload ()
 Unloads the buffer object from the video card.
 vbuffer_mixin (const int &target, const int &gl_mode, const gsgl::index_t initial_capacity=0)
virtual ~vbuffer_mixin ()

Protected Member Functions

virtual gsgl::index_t buffer_size ()
virtual size_t element_size ()
virtual void * get_ptr ()

Protected Attributes

int highest_dirty_index
int lowest_dirty_index

Private Attributes

gsgl::data::simple_array< T > buffer

Constructor & Destructor Documentation

vbuffer_mixin ( const int &  target,
const int &  gl_mode,
const gsgl::index_t  initial_capacity = 0 
) [inline]

Definition at line 105 of file vbuffer.hpp.

virtual ~vbuffer_mixin (  )  [inline, virtual]

Definition at line 107 of file vbuffer.hpp.


Member Function Documentation

void append ( const T &  t  )  [inline]

Definition at line 112 of file vbuffer.hpp.

Referenced by clipmap_ring::init(), and simple_sphere::simple_sphere().

void bind (  )  [inherited]

virtual gsgl::index_t buffer_size (  )  [inline, protected, virtual]

Implements vbuffer_base.

Definition at line 118 of file vbuffer.hpp.

virtual size_t element_size (  )  [inline, protected, virtual]

Implements vbuffer_base.

Definition at line 119 of file vbuffer.hpp.

gsgl::data::simple_array<T>& get_buffer (  )  [inline]

Definition at line 109 of file vbuffer.hpp.

virtual void* get_ptr (  )  [inline, protected, virtual]

Implements vbuffer_base.

Definition at line 120 of file vbuffer.hpp.

void load (  )  [inherited]

Loads the buffer object into the video card.

Definition at line 60 of file vbuffer.cpp.

References CHECK_GL_ERRORS, and vbuffer_base::opengl_id.

Referenced by vbuffer_base::bind(), and submesh::load().

T& operator[] ( const gsgl::index_t i  )  [inline]

Definition at line 115 of file vbuffer.hpp.

const T& operator[] ( const gsgl::index_t i  )  const [inline]

Definition at line 114 of file vbuffer.hpp.

gsgl::index_t size (  )  const [inline]

Definition at line 111 of file vbuffer.hpp.

Referenced by checkered_box::draw(), submesh::draw(), and clipmap_ring::init().

void unbind (  )  [inherited]

Unbinds the buffer object for use with OpenGL.

Definition at line 116 of file vbuffer.cpp.

References vbuffer_base::target.

void unload (  )  [inherited]

Unloads the buffer object from the video card.

Definition at line 68 of file vbuffer.cpp.

References CHECK_GL_ERRORS, and vbuffer_base::opengl_id.

Referenced by checkered_box::cleanup(), submesh::unload(), and vbuffer_base::~vbuffer_base().


Member Data Documentation

int highest_dirty_index [protected, inherited]

Definition at line 87 of file vbuffer.hpp.

Referenced by vbuffer_base::bind(), and vbuffer_mixin< unsigned int >::operator[]().

int lowest_dirty_index [protected, inherited]

Definition at line 87 of file vbuffer.hpp.

Referenced by vbuffer_base::bind(), and vbuffer_mixin< unsigned int >::operator[]().


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

Generated on Sat Mar 1 13:50:07 2008 for Periapsis Project by  doxygen 1.5.5