Skip to main content

write_physics_obj

Function write_physics_obj 

Source
pub fn write_physics_obj(mesh: &PhysicsObjMesh) -> String
Expand description

Serialise a PhysicsObjMesh to the extended OBJ text format.

Writes:

  • v x y z for each vertex, optionally followed by # phys_vel vx vy vz
  • # phys_density name value for each material
  • usemtl name / f i j k for each face