12 #include <osg/MatrixTransform>
13 #include <osg/Drawable>
14 #include <tbb/concurrent_vector.h>
20 class DtDiGuyScenario;
21 class DtDiGuyOsgGraphicsInstanceGroup;
22 class DtGlTextureBufferObject;
49 virtual void copy_tbo_data(
const int& num_floats,
const float* data);
56 mutable tbb::concurrent_vector< DtDiGuyOsgGraphicsInstanceGroup*>
myDrawables;
76 virtual osg::Object*
clone(
const osg::CopyOp& copyop = osg::CopyOp::SHALLOW_COPY)
const ;
Contains the DtOsgTextureBufferObjectApplyAttribute class.
Wrapper for OpenGL Texture Buffer Object.
Definition: DtGlTextureBufferObject.h:27
virtual void reset()
called every frame at the beginning to clear out drawables list
DtDiGuyInstanceDrawable()
ctor
osg::ref_ptr< TextureBufferObjectApplyAttribute > m_diguy_texture_buffer_attribute
Definition: DtDiGuyInstanceDrawable.h:63
osg::Vec3d myMutableCameraPosition
Definition: DtDiGuyInstanceDrawable.h:59
virtual void addDrawable(DtDiGuyOsgGraphicsInstanceGroup *drawable)
adds an instanced drawable
tbb::concurrent_vector< DtDiGuyOsgGraphicsInstanceGroup * > myTransparentDrawables
Definition: DtDiGuyInstanceDrawable.h:57
virtual osg::Object * clone(const osg::CopyOp ©op=osg::CopyOp::SHALLOW_COPY) const
Clone this object.
osg::ref_ptr< osg::StateAttribute > myShaderProgram
Definition: DtDiGuyInstanceDrawable.h:60
virtual void releaseGLObjects(osg::State *state) const
releases texture data
virtual ~DtDiGuyInstanceDrawable()
dtor
virtual void setupTextureBufferObject()
virtual void copy_tbo_data(const int &num_floats, const float *data)
function called by main thread job to get data down to the shared GPU
bool m_ready_for_clear
diguy updates add stuff to drawable list, but sometimes that happens 2x, not sure why...
Definition: DtDiGuyInstanceDrawable.h:68
Class that renders all the diguy instance objects in one osg drawable, major performance improvement...
Definition: DtDiGuyInstanceDrawable.h:26
DtGlTextureBufferObject * m_diguy_texture_buffer
Definition: DtDiGuyInstanceDrawable.h:62
tbb::concurrent_vector< DtDiGuyOsgGraphicsInstanceGroup * > myDrawables
Definition: DtDiGuyInstanceDrawable.h:56
virtual void drawImplementation(osg::RenderInfo &renderInfo) const
draws all the drawables.
This class is part of the DI-Guy Graphics API.
Definition: DtDiGuyOsgGraphicsInstanceGroup.h:36