diff options
| author | Roman <rskbox@gmail.com> | 2024-07-01 11:49:41 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-07-01 10:49:41 +0200 |
| commit | 66b6b55ea21b6b43fd1870dba0fab3cc96a3fa4b (patch) | |
| tree | 6e594f42dca259b8cdf81e0e05a6784b9f0b43be /src | |
| parent | 0089365e661bf487073e58e4e800894dc4e4fc41 (diff) | |
| download | rapier-66b6b55ea21b6b43fd1870dba0fab3cc96a3fa4b.tar.gz rapier-66b6b55ea21b6b43fd1870dba0fab3cc96a3fa4b.tar.bz2 rapier-66b6b55ea21b6b43fd1870dba0fab3cc96a3fa4b.zip | |
Rotation gizmo for Ball 2d collider (#670)
Diffstat (limited to 'src')
| -rw-r--r-- | src/pipeline/debug_render_pipeline/debug_render_pipeline.rs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/pipeline/debug_render_pipeline/debug_render_pipeline.rs b/src/pipeline/debug_render_pipeline/debug_render_pipeline.rs index 831f815..f2e23cd 100644 --- a/src/pipeline/debug_render_pipeline/debug_render_pipeline.rs +++ b/src/pipeline/debug_render_pipeline/debug_render_pipeline.rs @@ -369,6 +369,13 @@ impl DebugRenderPipeline { &Vector::repeat(s.radius * 2.0), color, true, + ); + // Draw a radius line to visualize rotation + backend.draw_line( + object, + pos * Point::new(s.radius * 0.2, 0.0), + pos * Point::new(s.radius * 0.8, 0.0), + color, ) } TypedShape::Cuboid(s) => { |
