|
| virtual void | Enable (bool enable)=0 |
| | Enable or disable debug drawing for the entire scene.
|
| virtual void | EnableActor (ActorHandle actor, bool enable, Error &error)=0 |
| | Enable or disable debug drawing for a specific actor.
|
| virtual void | EnableFeature (int index, bool enable)=0 |
| | Enable or disable a specific feature.
|
| virtual int | FindFeature (std::string_view name) const =0 |
| | Find a feature by name.
|
| virtual DebugDrawData | GatherData ()=0 |
| | Generate debug draw primitives for all currently enabled features.
|
| virtual std::string_view | GetFeatureDescription (int index) const =0 |
| | Get the description of a feature by index.
|
| virtual std::string_view | GetFeatureName (int index) const =0 |
| | Get the name of a feature by index.
|
| virtual int | GetNumFeatures () const =0 |
| | Get the number of debug draw features available.
|
| virtual bool | IsEnabled () const =0 |
| | Check if debug drawing is enabled for the scene.
|
| virtual bool | IsFeatureEnabled (int index) const =0 |
| | Check if a feature is currently enabled.
|
Manages debug visualization features for a scene.
Provides a feature-based system for visualizing various aspects of the physics simulation. The client application is responsible for rendering the generated primitives using its own graphics API. Features can be individually enabled or disabled, such as visualizing contact points, normals, velocities, or AABBs.
- Note
- Must be accessed on the same thread as the owning Scene.
-
Debug draw is disabled by default.
-
If consuming the data on a different thread, the client must deep-copy the underlying data into client-owned buffers before the scene thread calls GatherData again or modifies the Scene. Copying DebugDrawData itself is a shallow copy of Span views into internal buffers and does not transfer ownership.
- Warning
- Debug drawing has significant performance overhead due to geometry generation and data gathering.
- See also
- Scene::GetDebugDraw, DebugDrawData
Definition at line 33 of file mochi_debug_draw.h.