21#include <matrix/vlVector.h>
23#include <osg/Drawable>
66 virtual void draw(DtDebugCanvas& drawList) = 0;
154 virtual std::vector<std::pair<std::string, std::string>>
layerNames(
155 double timeoutTime = 0.f,
const std::string& group =
"");
273 using CanvasMap = std::map<std::pair<void*, bool>, DtDebugCanvas*>;
Class for representing and manipulating RGBA colors.
Definition color.h:22
Fill
Fill mode enumeration for rendering.
Definition color.h:26
Base class for all debug draw commands.
Definition debugRenderer.h:45
bool myClip
Whether to clip against the view frustum.
Definition debugRenderer.h:87
double myTime
Remaining time in seconds for display.
Definition debugRenderer.h:85
DtVector myEyepoint
Eye position for view-dependent debug visuals.
Definition debugRenderer.h:79
DtColor::Fill myFill
Fill mode for the debug visual.
Definition debugRenderer.h:83
bool my3D
Whether this is a 3D visual.
Definition debugRenderer.h:89
virtual bool ended()
Checks if this command has expired.
Definition debugRenderer.h:72
virtual ~DtDebugDrawCommand()
Virtual destructor.
Definition debugRenderer.h:62
virtual void reduceTime(double delta)
Reduces the remaining display time for this command.
Definition debugRenderer.h:69
DtDebugDrawCommand(DtColor color, DtColor::Fill fill, bool clip, const double &time, bool is3D)
Constructor for debug draw commands.
Definition debugRenderer.h:53
virtual void draw(DtDebugCanvas &drawList)=0
Pure virtual draw method that must be implemented by derived classes.
virtual bool get3D()
Checks if this is a 3D visual.
Definition debugRenderer.h:75
DtColor myColor
Color of the debug visual.
Definition debugRenderer.h:81
virtual makVre::DtVreMessageResult handleDrawTris(makVre::DtVreMessage *msg)
Handles triangle drawing messages.
float myDebugMenuTimeout
Timeout for debug menu visibility.
Definition debugRenderer.h:236
virtual void setEnabled(bool setting)
Enables or disables debug rendering.
virtual makVre::DtVreMessageResult handleDrawCube(makVre::DtVreMessage *msg)
Handles cube drawing messages.
virtual void setLayerEnabled(const std::string &layerName, bool setting)
Enables or disables a specific debug layer.
osg::ref_ptr< osg::Drawable > my2dDrawable
2D drawable for rendering debug elements
Definition debugRenderer.h:278
virtual makVre::DtVreMessageResult handleDrawLine(makVre::DtVreMessage *msg)
Handles line drawing messages.
float myMainScreenHeight
Main screen height in pixels.
Definition debugRenderer.h:232
float myMainScreenWidth
Main screen width in pixels.
Definition debugRenderer.h:234
virtual makVre::DtVreMessageResult handleDrawTextPanel(makVre::DtVreMessage *msg)
Handles text panel drawing messages.
virtual makVre::DtVreMessageResult handleDrawSphere(makVre::DtVreMessage *msg)
Handles sphere drawing messages.
std::map< std::pair< void *, bool >, DtDebugCanvas * > CanvasMap
Map of canvases for different rendering contexts.
Definition debugRenderer.h:273
void setRenderTimeout(float timeout)
Sets the render timeout value.
friend DtVreDebugManager
Definition debugRenderer.h:179
DtFilename myFontFilename
Font filename for text rendering.
Definition debugRenderer.h:283
std::map< std::string, DrawLayer > DrawLayerMap
Map of layer IDs to layer data.
Definition debugRenderer.h:263
float getRenderTimeout()
Gets the render timeout value.
void addDrawCmd(const std::string &layerId, const std::string &layerName, DtDebugDrawCommand *cmd)
Adds a draw command to a specific layer.
osg::ref_ptr< osg::Drawable > my3dDrawable
3D drawable for rendering debug elements
Definition debugRenderer.h:280
CanvasMap myCanvasMap
Map of all debug canvases.
Definition debugRenderer.h:275
bool myIsEnabled
Flag indicating if debug rendering is enabled.
Definition debugRenderer.h:270
DtFilename myVsFilename
Vertex shader filename.
Definition debugRenderer.h:285
virtual bool isEnabled()
Checks if debug rendering is enabled.
virtual std::vector< std::pair< std::string, std::string > > layerNames(double timeoutTime=0.f, const std::string &group="")
Gets the names of all available debug layers.
DrawLayerMap::iterator DrawLayerMapIter
Iterator for the draw layer map.
Definition debugRenderer.h:265
makVrv::DtDe & myDe
Reference to the graphics engine.
Definition debugRenderer.h:229
virtual makVre::DtVreMessageResult handleDrawText2d(makVre::DtVreMessage *msg)
Handles 2D text drawing messages.
DtDebugRenderer(makVrv::DtDe &de)
Constructor for debug renderer.
virtual void debugCallback()
Debug callback function.
DrawLayerMap myDrawLayerMap
Map of all debug layers.
Definition debugRenderer.h:267
virtual bool isLayerEnabled(const std::string &layerName)
Checks if a specific debug layer is enabled.
virtual makVre::DtVreMessageResult handleDrawText3d(makVre::DtVreMessage *msg)
Handles 3D text drawing messages.
virtual bool render(void *context, DtDebugRenderParameters ¶ms)
Main rendering function for debug visuals.
virtual ~DtDebugRenderer()
Virtual destructor.
virtual makVre::DtVreMessageResult handleDrawGraph(makVre::DtVreMessage *msg)
Handles graph drawing messages.
DtFilename myFsFilename
Fragment shader filename.
Definition debugRenderer.h:287
Main debug manager class for VREngage.
Definition debugManager.h:132
Abstract base class for all VREngage messages.
Definition vreMessage.h:50
Provides color representation and manipulation functionality.
Contains debug rendering macros for the VREngage debug system.
Defines export macros for the VREngage Debug Manager library.
#define DEBUGMANAGER_DLL
Export/import macro for non-Windows platforms.
Definition export.h:40
Include export definitions for this library.
Definition glsVreMessageUtil.h:49
DtVreMessageResult
Enumeration of possible message handling results.
Definition vreMessage.h:33
Definition appLauncherComponent.h:28
makVrv::DtDe * de()
Gets the display element pointer used by the plugin.
Parameters for debug rendering.
Definition debugRenderer.h:97
float perspective[16]
Perspective projection matrix.
Definition debugRenderer.h:107
bool is3d
Whether rendering in 3D mode.
Definition debugRenderer.h:103
float screenHeight
Height of the screen in pixels.
Definition debugRenderer.h:101
DtDebugRenderParameters()
Default constructor.
Definition debugRenderer.h:116
float ortho[16]
Orthographic projection matrix.
Definition debugRenderer.h:105
float screenWidth
Width of the screen in pixels.
Definition debugRenderer.h:99
DtVector obsPos
Observer position.
Definition debugRenderer.h:111
float view[16]
View matrix.
Definition debugRenderer.h:109
std::string myLayerMapDisplayName
Display name of the layer.
Definition debugRenderer.h:244
double mySinceLastUpdateTime
Time since last update.
Definition debugRenderer.h:248
DrawLayer()
Default constructor initializing layer as disabled.
Definition debugRenderer.h:255
bool myIsEnabled
Whether the layer is enabled.
Definition debugRenderer.h:246
bool myIs3D
Whether this is a 3D layer.
Definition debugRenderer.h:250
std::list< DtDebugDrawCommand * > myDrawList
List of draw commands for this layer.
Definition debugRenderer.h:252