all-is-cubes icon indicating copy to clipboard operation
all-is-cubes copied to clipboard

Rendering for non-block objects (bodies, particles)

Open kpreid opened this issue 3 years ago • 0 comments

All is cubes, but there are reasons for some of those cubes to not be necessarily on the Space grid.

  • Particles for assorted visual effects.
  • Physics bodies that can move smoothly (without large update and rendering cost), such as multiple characters, dropped items, and projectiles.

For the simple case of fully opaque meshes, this will be a straightforward matter of adding separate instanced meshes, but:

  • The raytracer will need to be extended to be able to trace simultaneously through several potentially-intersecting shapes. This is architecturally feasible, but will come at a computation cost. (But the raytracer is also more of a “because we could” feature than something that necessarily needs to support everything well.)
  • The mesh-based GPU renderer will have trouble with depth sorting when a moving object is also transparent. (Perhaps we should recommend that all particles be either fully opaque or almost entirely transparent, to reduce the effect of sorting errors?)
  • Open question: should objects be able to rotate smoothly, or should we require only right angles?
  • Open question: What sort of inputs should be able to be used as the appearance of particles or bodies? Are they all Blocks, perhaps?

See also #301 for the simulation of these objects.

kpreid avatar Oct 18 '22 01:10 kpreid