voxcraft / voxcraft-sim

a GPU-accelerated voxel-based physics engine
Creative Commons Zero v1.0 Universal
48 stars 11 forks source link

[enchancement] Separate body from world. #28

Closed skriegman closed 3 years ago

skriegman commented 4 years ago

Create an <Env> and <Body> which are combined with logical OR to give <Data>.

<Body> is nested within an <Env> by shifting its <BodyCoordinates>.

Then it is trivial to generalize the specific methods I implemented in dev-growth for env.reset, body.reset, body.remove.

Of course multiple contiguous geometries, separated by zeroes, can still exist within <Body>. Or the multi-body matrices could be supplanted by a mechanism that draws single body .vxd files out of a directory and combines them in a swarm within an <Env>.

Multiple <Env> would be useful. They should be stored in a single .vxa if they are not coevolved.