19 #include <osg/Drawable>
33 class DtOsgGizmoRenderer;
34 class DtDebugDrawCallbackInterface;
60 virtual void releaseGLObjects(osg::State* state=0)
const;
63 virtual void drawImplementation(osg::RenderInfo& renderInfo)
const;
69 virtual void addWsLine(
const osg::Vec3d& p1,
const osg::Vec3d& p2,
const osg::Vec4f& color1,
const osg::Vec4f& color2,
bool depth_test =
true);
75 virtual void renderWsBoxIntoVbo(
const osg::Vec3d& p1,
const osg::Vec3d& p2,
76 const osg::Vec4f& color);
79 virtual void renderBoxFromPointsIntoVbo(
const osg::Matrixf& model_matrix,
80 const osg::Vec3f& pMin,
const osg::Vec3f& pMax,
const osg::Vec4f& color);
83 virtual void renderSphereIntoVbo(
const osg::Vec3f& localCenter,
const osg::Vec3f& radii,
const osg::Matrixf& xform,
84 const osg::Vec4f& force_color);
87 virtual void renderCircleIntoVbo(
const osg::Vec3f& localCenter,
const float radii,
const osg::Matrixf& xform,
88 const osg::Vec4f& force_color);
91 virtual void renderHemisphereIntoVbo(
const osg::Vec3f& localCenter,
const osg::Vec3f& radii,
const osg::Matrixf& xform,
92 const osg::Vec4f& force_color);
95 virtual void renderEllipseIntoVbo(
const osg::Vec3f& localCenter,
const osg::Vec2f& radii,
const osg::Matrixf& xform,
96 const osg::Vec4f& force_color);
99 virtual void renderBoxIntoVbo(
const osg::Vec3f& localCenter,
const osg::Vec3f& localMin,
const osg::Vec3f& localMax,
const osg::Matrixf& xform,
100 const osg::Vec4f& force_color);
103 virtual void drawStreamedData(osg::RenderInfo& renderInfo,
int primitive_type,
104 const std::vector<osg::Vec3f>& verts,
const std::vector<osg::Vec4f>* colors,
const std::vector<osg::Vec3f>* normals,
105 const std::vector<unsigned short>* index_buffer,
106 const osg::Vec4f& default_color = osg::Vec4f(1, 1, 1, 1));
110 virtual void setCameraPos(
const osg::Vec3& pos);
113 virtual void drawImplementationNonConst(osg::RenderInfo& renderInfo);
116 virtual bool anythingToDraw(
void)
const;
a helper struct to send basic primitives to video card
Definition: DtStreamedVboData.h:25
Contains makVrv::DtStreamedVboData class.
std::array< std::vector< osg::Vec3f >, 2 > myScratchVerts
Definition: DtOsgGizmoRenderer.h:131
DtStreamedVboData myDynamicVbo
Definition: DtOsgGizmoRenderer.h:120
#define DT_DLL_VRVOSG
Definition: vrvOsg.h:23
std::vector< unsigned short > myLineStripIndexes
Definition: DtOsgGizmoRenderer.h:126
unsigned int GLuint
Definition: DtGlTextureBufferObject.h:18
A simple interface for allowing the various systems to draw lines at the right time.
Definition: DtDebugDrawCallbackInterface.h:30
a class to quickly render a bunch of basic primitives as debugging aids basic overview, create an adapter that inherits from DtDebugDrawCallbackInterface then call DtOsgGizmoRenderer::addDebugDrawerCallback() to register it with the system. Your code will then get called while the system is drawing, user should then add various primitives that will get rendered in one big batch after all the callbacks. See DtOsgLightDebugAdapter::drawDebugLines() for an example.
Definition: DtOsgGizmoRenderer.h:44
std::array< std::vector< osg::Vec4f >, 2 > myScratchColors
Definition: DtOsgGizmoRenderer.h:132
DtDe & myDe
Definition: DtOsgGizmoRenderer.h:119
Contains makVrv::DtVirtualBaseClass class.
osg::Vec3d myCameraPosition
Definition: DtOsgGizmoRenderer.h:130
std::vector< osg::Vec4f > myLineStripColors
Definition: DtOsgGizmoRenderer.h:125
GLuint myVao
Definition: DtOsgGizmoRenderer.h:128
Contains DLL export macros.
The DtDe is the core component of any VR-Vantage application. It owns a DtRenderer, DtDeCommunicator, as well as a DtDisplay and other things.
Definition: DtDe.h:76
DtStreamedVboData myAxisVbo
Definition: DtOsgGizmoRenderer.h:121
std::vector< osg::Vec3f > myLineStripVerts
Definition: DtOsgGizmoRenderer.h:124
std::vector< DtDebugDrawCallbackInterface * > myExtraDebugDrawObjects
Definition: DtOsgGizmoRenderer.h:133