diff options
| author | Crozet Sébastien <developer@crozet.re> | 2020-11-02 15:07:50 +0100 |
|---|---|---|
| committer | Crozet Sébastien <developer@crozet.re> | 2020-11-02 15:08:46 +0100 |
| commit | 01af6c09a786ec2d6475531a7dac873eeffa3a3e (patch) | |
| tree | 2f7a31860f31771571535effe75db426f7eb63ea /src/geometry/polyhedron_feature3d.rs | |
| parent | 4b8242b9c267a9412c88793575db37f79c544ca2 (diff) | |
| download | rapier-01af6c09a786ec2d6475531a7dac873eeffa3a3e.tar.gz rapier-01af6c09a786ec2d6475531a7dac873eeffa3a3e.tar.bz2 rapier-01af6c09a786ec2d6475531a7dac873eeffa3a3e.zip | |
Fix simulation reaching different states when started from different snaphots.
Diffstat (limited to 'src/geometry/polyhedron_feature3d.rs')
| -rw-r--r-- | src/geometry/polyhedron_feature3d.rs | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/geometry/polyhedron_feature3d.rs b/src/geometry/polyhedron_feature3d.rs index e88674e..d7f0a23 100644 --- a/src/geometry/polyhedron_feature3d.rs +++ b/src/geometry/polyhedron_feature3d.rs @@ -14,6 +14,18 @@ pub struct PolyhedronFace { pub num_vertices: usize, } +impl Default for PolyhedronFace { + fn default() -> Self { + Self { + vertices: [Point::origin(); 4], + vids: [0; 4], + eids: [0; 4], + fid: 0, + num_vertices: 0, + } + } +} + impl From<CuboidFeatureFace> for PolyhedronFace { fn from(face: CuboidFeatureFace) -> Self { Self { |
