diff options
| author | Robert Hrusecky <robert.hrusecky@utexas.edu> | 2020-10-29 18:09:41 -0500 |
|---|---|---|
| committer | Robert Hrusecky <robert.hrusecky@utexas.edu> | 2020-10-29 18:09:41 -0500 |
| commit | bcec54ef31d987cf20b493628a20777183a95f65 (patch) | |
| tree | cee40c0467c04f1f02861342e20ce8223ca6d99b /src_testbed/objects/node.rs | |
| parent | dd8e25bc4756b8bd01d283b5d7e7c5daa9a1af3f (diff) | |
| parent | 4b8242b9c267a9412c88793575db37f79c544ca2 (diff) | |
| download | rapier-bcec54ef31d987cf20b493628a20777183a95f65.tar.gz rapier-bcec54ef31d987cf20b493628a20777183a95f65.tar.bz2 rapier-bcec54ef31d987cf20b493628a20777183a95f65.zip | |
Merge branch 'master' into infinite_fall_memory
Fix merge conflict resulting from "axii" spelling correction
Diffstat (limited to 'src_testbed/objects/node.rs')
| -rw-r--r-- | src_testbed/objects/node.rs | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src_testbed/objects/node.rs b/src_testbed/objects/node.rs index 93b5eac..d1de799 100644 --- a/src_testbed/objects/node.rs +++ b/src_testbed/objects/node.rs @@ -10,6 +10,8 @@ use crate::objects::mesh::Mesh; use kiss3d::window::Window; use na::Point3; +use crate::objects::cone::Cone; +use crate::objects::cylinder::Cylinder; use rapier::geometry::{ColliderHandle, ColliderSet}; use rapier::math::Isometry; @@ -28,6 +30,8 @@ pub enum Node { // Polyline(Polyline), Mesh(Mesh), Convex(Convex), + Cylinder(Cylinder), + Cone(Cone), } impl Node { @@ -42,6 +46,8 @@ impl Node { // Node::Polyline(ref mut n) => n.select(), Node::Mesh(ref mut n) => n.select(), Node::Convex(ref mut n) => n.select(), + Node::Cylinder(ref mut n) => n.select(), + Node::Cone(ref mut n) => n.select(), } } @@ -56,6 +62,8 @@ impl Node { // Node::Polyline(ref mut n) => n.unselect(), Node::Mesh(ref mut n) => n.unselect(), Node::Convex(ref mut n) => n.unselect(), + Node::Cylinder(ref mut n) => n.unselect(), + Node::Cone(ref mut n) => n.unselect(), } } @@ -70,6 +78,8 @@ impl Node { // Node::Polyline(ref mut n) => n.update(colliders), Node::Mesh(ref mut n) => n.update(colliders), Node::Convex(ref mut n) => n.update(colliders), + Node::Cylinder(ref mut n) => n.update(colliders), + Node::Cone(ref mut n) => n.update(colliders), } } @@ -97,6 +107,8 @@ impl Node { Node::HeightField(ref n) => Some(n.scene_node()), Node::Mesh(ref n) => Some(n.scene_node()), Node::Convex(ref n) => Some(n.scene_node()), + Node::Cylinder(ref n) => Some(n.scene_node()), + Node::Cone(ref n) => Some(n.scene_node()), #[cfg(feature = "dim2")] _ => None, } @@ -113,6 +125,8 @@ impl Node { Node::HeightField(ref mut n) => Some(n.scene_node_mut()), Node::Mesh(ref mut n) => Some(n.scene_node_mut()), Node::Convex(ref mut n) => Some(n.scene_node_mut()), + Node::Cylinder(ref mut n) => Some(n.scene_node_mut()), + Node::Cone(ref mut n) => Some(n.scene_node_mut()), #[cfg(feature = "dim2")] _ => None, } @@ -129,6 +143,8 @@ impl Node { // Node::Polyline(ref n) => n.object(), Node::Mesh(ref n) => n.object(), Node::Convex(ref n) => n.object(), + Node::Cylinder(ref n) => n.object(), + Node::Cone(ref n) => n.object(), } } @@ -143,6 +159,8 @@ impl Node { // Node::Polyline(ref mut n) => n.set_color(color), Node::Mesh(ref mut n) => n.set_color(color), Node::Convex(ref mut n) => n.set_color(color), + Node::Cylinder(ref mut n) => n.set_color(color), + Node::Cone(ref mut n) => n.set_color(color), } } } |
