Move ColliderShape out of Rapier.

This commit is contained in:
Crozet Sébastien
2021-01-22 18:10:54 +01:00
parent b779eb261e
commit 57072f3ba7
7 changed files with 49 additions and 435 deletions

View File

@@ -1,6 +1,6 @@
use na::{ComplexField, DMatrix, Isometry3, Point3, Vector3};
use rapier3d::dynamics::{JointSet, RigidBodyBuilder, RigidBodySet};
use rapier3d::geometry::{ColliderBuilder, ColliderSet, ColliderShape};
use rapier3d::geometry::{ColliderBuilder, ColliderSet, SharedShape};
use rapier_testbed3d::Testbed;
pub fn init_world(testbed: &mut Testbed) {
@@ -70,15 +70,15 @@ pub fn init_world(testbed: &mut Testbed) {
let shapes = vec![
(
Isometry3::identity(),
ColliderShape::cuboid(rad, rad / 2.0, rad / 2.0),
SharedShape::cuboid(rad, rad / 2.0, rad / 2.0),
),
(
Isometry3::translation(rad, 0.0, 0.0),
ColliderShape::cuboid(rad / 2.0, rad, rad / 2.0),
SharedShape::cuboid(rad / 2.0, rad, rad / 2.0),
),
(
Isometry3::translation(-rad, 0.0, 0.0),
ColliderShape::cuboid(rad / 2.0, rad, rad / 2.0),
SharedShape::cuboid(rad / 2.0, rad, rad / 2.0),
),
];