feat: reduce the amount of duplicate work the broad-phase is doing for user changes and CCD + release v0.28.0 (#872)
* feat: reduce the amount of duplicate work the broad-phase is doing for user changes and CCD * Release v0.28.0 * chore: fix warnings * chore: clippy fixes * chore: more clippy fixes
This commit is contained in:
@@ -12,7 +12,7 @@ other-backends = ["rapier_testbed3d/other-backends"]
|
||||
enhanced-determinism = ["rapier3d/enhanced-determinism"]
|
||||
|
||||
[dependencies]
|
||||
rand = "0.8"
|
||||
rand = "0.9"
|
||||
Inflector = "0.11"
|
||||
oorandom = "11"
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
use rand::distributions::{Distribution, Standard};
|
||||
use rand::distr::{Distribution, StandardUniform};
|
||||
use rand::{SeedableRng, rngs::StdRng};
|
||||
use rapier_testbed3d::Testbed;
|
||||
use rapier3d::prelude::*;
|
||||
@@ -39,7 +39,7 @@ pub fn init_world(testbed: &mut Testbed) {
|
||||
let mut offset = -(num as f32) * shift * 0.5;
|
||||
|
||||
let mut rng = StdRng::seed_from_u64(0);
|
||||
let distribution = Standard;
|
||||
let distribution = StandardUniform;
|
||||
|
||||
for j in 0usize..47 {
|
||||
for i in 0..num {
|
||||
|
||||
@@ -51,10 +51,7 @@ pub fn init_world(testbed: &mut Testbed) {
|
||||
let t1 = std::time::Instant::now();
|
||||
let max_toi = ray_ball_radius - 1.0;
|
||||
|
||||
let Some(broad_phase) = physics.broad_phase.downcast_ref::<BroadPhaseBvh>() else {
|
||||
return;
|
||||
};
|
||||
let query_pipeline = broad_phase.as_query_pipeline(
|
||||
let query_pipeline = physics.broad_phase.as_query_pipeline(
|
||||
physics.narrow_phase.query_dispatcher(),
|
||||
&physics.bodies,
|
||||
&physics.colliders,
|
||||
|
||||
Reference in New Issue
Block a user