Skip to content

physics: rigid-body visual polish — bodies fall but render swallows them in default scenes #181

Description

@havokentity

Context

User feedback during integration smoke test: "btw rigidbodies, nothing is falling. is this another 'oh i created rigidbodies but theres no real bodies' thing?"

Investigation (Mac, integration HEAD)

Ran A/B on tests/goldens/scenes/phys_rb_smoke.cfg:

Test Result
phys_enabled 0 vs phys_enabled 1 @ frame 60 11591 pixels differ (3.77%), max delta 407
Isolation render (pt_smoke_skip_csg_seed 1 + pt_smoke_skip_prim_seed 1) Bodies clearly visible & falling
Frame 4 → 30 → 90 progression Center body falls from y≈20 → 70 → 110 in screen-space (gravity integrating)

Physics is fully working. Bodies translate under gravity, collisions hit ground, spawns are continuous.

What the user sees in the default render

  • 5 rigid bodies (radius 0.3–0.4m) spawned at heights y=4 to y=7
  • Render as faint white spheres against bright procedural sky
  • Visually swallowed by the cornell_csg seed cluster which renders front-and-center in every default scene
  • At first glance "nothing is falling" because the cluster dominates

NOT the same as smoke MVP

Smoke MVP (#180) was a genuinely incomplete optical model (in-scatter only, no Beer-Lambert until opt-in). Rigid bodies are fully integrated — they just lack visual distinction in the default render.

Wave-2 fixes (proposed)

  • Colored materials per body type (red for spheres, blue for boxes) so they pop visually
  • OR: dedicated phys_rb_demo.cfg fixture without cornell_csg cluster, used as the user-facing rigid-body demo
  • OR: emissive tag on bodies so they self-illuminate above the cluster
  • Velocity-color overlay (r_phys_show_velocity 1) for debug — color bodies by speed
  • Trails / motion blur via shutter-jitter (renderer: motion blur via shutter-time jitter (PT-native) #85) so falling is unmistakable in a single frame

Acceptance

Single-frame screenshot of default phys_rb_smoke.cfg should make it obvious bodies are falling — without needing A/B against phys_enabled 0.

Related

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions