|
VR-Engage
2.2
|
This singleton class provides the central interface for all debugging functionality in VREngage, including menu management, debug rendering, and debug message passing throughout the application.
#include <debugManager.h>
Static Public Member Functions | |
| static DtVreDebugManager * | instance () |
| static void | installFull (makVrv::DtDe &) |
| static void | installLite () |
| static void | shutdown () |
| static void | PushStyleCompact () |
| static void | PopStyleCompact () |
| static void | Indent () |
| static void | Unindent () |
| static void | HelpMarker (const std::string &desc) |
| static bool | IsDebuggerAttached (bool recheck=false) |
| static bool | ConditionalCheckbox (const std::string &enabledString, const std::string &disabledString, bool *val) |
Protected Member Functions | |
| DtVreDebugManager (makVrv::DtDe *) | |
| virtual | ~DtVreDebugManager () |
| DtVreDebugManager (DtVreDebugManager &)=delete | |
| DtVreDebugManager (DtVreDebugManager &&)=delete | |
| DtVreDebugManager & | operator= (DtVreDebugManager &)=delete |
| DtVreDebugManager & | operator= (DtVreDebugManager &&)=delete |
| virtual void | generalCallback () |
| virtual void | simCallback () |
| virtual void | loadDebugConfiguration () |
| virtual void | installDefaultDebugMessages () |
| void | drawVrEngageDebugOption () |
| DtVreMessageResult | handleDebugMetaData (DtVreMessage *msg) |
| DtVreMessageResult | handleDebugMetaEnable (DtVreMessage *msg) |
| DtVreMessageResult | handleDebugMetaRegister (DtVreMessage *msg) |
| DtVreMessageResult | handleDebugGlobalEnable (DtVreMessage *msg) |
Protected Attributes | |
| makVrv::DtDe * | myDe |
| DebugMenuConfigurationMap | myDebugConfigurationMap |
| DebugEnabledCallbackList | myDebugEnabledCallbackList |
| std::unique_ptr< DtDebugRenderer > | myDebugRenderer |
| std::unique_ptr< DtInitializer > | myDebugInitializer |
| bool | myDrawWindow |
| float | myIndentWidth |
| bool | myDebuggerAttached |
| bool | mySendingDebugMessages |
| bool | myLiteDebugManager |
| bool | myConsoleShown |
Static Protected Attributes | |
| static DtVreDebugManager * | theDebugManager |
|
explicitprotected |
Constructor for DtVreDebugManager.
Protected since this is a singleton class
| de | Pointer to the graphics engine (can be null for lite mode) |
Referenced by DtVreDebugManager(), DtVreDebugManager(), instance(), operator=(), and operator=().
|
protectedvirtual |
Virtual destructor.
Handles cleanup of debug manager resources
|
protecteddelete |
Copy constructor (deleted)
References DtVreDebugManager().
|
protecteddelete |
Move constructor (deleted)
References DtVreDebugManager().
|
static |
Gets the singleton debug manager instance.
References DtVreDebugManager().
|
static |
Installs the full debug system with rendering capabilities.
| de | The graphics engine to attach the debug renderer to |
|
static |
Installs a lightweight version of the debug system without rendering.
Use this when no graphics engine is available but debugging is still required
|
static |
Cleans up and shuts down the debug system.
Releases all resources and destroys the singleton instance
|
virtual |
Registers a callback for a specific debug menu section.
The callback will be invoked when the specified debug menu section is active
| sec | The section name to register the callback for |
| cb | The callback function to register |
| position | Where to place the callback in the execution order |
References makVre::BACK.
|
virtual |
Removes a previously registered debug menu callback.
| cb | The callback to remove |
|
virtual |
Registers a callback that is triggered when debug rendering is enabled/disabled.
This callback will be invoked when the debug rendering enabled state changes
| cb | The callback function to register |
| position | Where to place the callback in the execution order |
References makVre::BACK.
|
virtual |
Removes a previously registered debug enabled callback.
| cb | The callback to remove |
|
virtual |
Adds a new debug menu entry to the debug UI.
| name | The name of the menu entry |
| conf | The configuration for this menu entry |
|
virtual |
Removes a debug menu entry from the debug UI.
| name | The name of the menu entry to remove |
| DebugMenuConfigurationMap::iterator makVre::DtVreDebugManager::getDebugMenuConfiguration | ( | const std::string & | name | ) |
Gets an iterator to a debug menu configuration by name.
| name | The name of the menu configuration to find |
| bool makVre::DtVreDebugManager::getDebugProcess | ( | const std::string & | type, |
| DtSimulationAddress | address, | ||
| DtConfigurableDebugProcess & | proc ) |
Gets a debug process by type and simulation address.
| type | The type of debug process to find |
| address | The simulation address of the process |
| proc | The found debug process configuration (output parameter) |
|
virtual |
Draws the VREngage debug menu using ImGui.
This is the main drawing function that renders all registered debug UI elements. It should be called from the application's ImGui rendering pass.
| bool makVre::DtVreDebugManager::isDebugWindowVisible | ( | ) | const |
Checks if the debug window is currently visible.
| void makVre::DtVreDebugManager::setDebugWindowVisible | ( | bool | vis | ) |
Sets the visibility of the debug window.
| vis | True to show the window, false to hide it |
| bool makVre::DtVreDebugManager::getSendDebugMessages | ( | ) | const |
Checks if debug messages are being sent.
| void makVre::DtVreDebugManager::setSendDebugMessages | ( | bool | send | ) |
Enables or disables sending of debug messages.
| send | True to enable debug messages, false to disable |
| bool makVre::DtVreDebugManager::isLiteMode | ( | ) | const |
Checks if the debug system is running in lite mode.
| bool makVre::DtVreDebugManager::isFullMode | ( | ) | const |
Checks if the debug system is running in full mode.
|
inline |
Gets the debug initializer.
|
inline |
Gets the debug renderer instance.
|
static |
Pushes compact ImGui style settings.
Modifies ImGui style to use more compact layout for debug UI elements
|
static |
Pops compact ImGui style settings.
Restores the previous ImGui style settings after PushStyleCompact()
|
static |
Indents the ImGui content.
Adds indentation to subsequent ImGui elements
|
static |
Unindents the ImGui content.
Removes indentation from subsequent ImGui elements
|
static |
Displays a help marker with description text.
| desc | The description text to display in the help tooltip |
|
static |
Checks if a debugger is attached to the process.
| recheck | Force a recheck instead of using cached value |
|
static |
Creates a checkbox that displays different strings based on its state.
| enabledString | Text to display when checkbox is checked |
| disabledString | Text to display when checkbox is unchecked |
| val | Pointer to the boolean value controlled by the checkbox |
|
protecteddelete |
Copy assignment operator (deleted)
References DtVreDebugManager().
|
protecteddelete |
Move assignment operator (deleted)
References DtVreDebugManager().
|
protectedvirtual |
General callback for debug events.
Called when general debug events need to be processed
|
protectedvirtual |
Simulation-specific callback for debug events.
Called when simulation-specific debug events need to be processed
|
protectedvirtual |
Loads debug configuration settings.
Initializes the debug configuration from saved settings
|
protectedvirtual |
Installs default debug message handlers.
Sets up the standard debug message handlers for the system
|
protected |
Draws the "Show VR-Engage Debug Menu" option.
Renders the toggle option for showing/hiding the debug menu
|
protected |
Handles debug metadata messages.
| msg | The message to process |
|
protected |
Handles debug meta enable/disable messages.
| msg | The message to process |
|
protected |
Handles debug meta registration messages.
| msg | The message to process |
|
protected |
Handles global debug enable/disable messages.
| msg | The message to process |
|
staticprotected |
Singleton instance of the debug manager.
|
protected |
Pointer to the graphics engine.
|
protected |
Map of debug menu configurations and their callbacks.
|
protected |
List of callbacks to invoke when debug is enabled/disabled.
|
protected |
Debug renderer instance owned by the manager.
|
protected |
Debug initializer instance.
|
protected |
Flag indicating if the debug window should be drawn.
|
protected |
Width of indentation for ImGui elements.
|
protected |
Flag indicating if a debugger is attached to the process.
|
protected |
Flag indicating if debug messages should be sent.
|
protected |
Flag indicating if running in lite mode.
|
protected |
Flag indicating if the debug console is shown.