mirror of
https://github.com/bevyengine/bevy
synced 2024-11-10 07:04:33 +00:00
Fix tracing with transform_hierarchy
example (#14374)
# Objective Fixes #7433 Alternative to #14323 ## Solution Add `DefaultPlugins` so we actually have tracing spans when using `trace_tracy` or `trace_chrome`. ## Testing ``` cargo run --release --features trace_tracy --example transform_hierarchy large_tree ``` This now connects to Tracy and sends a bunch of data.
This commit is contained in:
parent
c0cebfef45
commit
490792ba7a
1 changed files with 14 additions and 2 deletions
|
@ -18,7 +18,11 @@
|
|||
//! | `humanoids_inactive` | 4000 humanoid rigs. Only 10 are active. |
|
||||
//! | `humanoids_mixed` | 2000 active and 2000 inactive humanoid rigs. |
|
||||
|
||||
use bevy::prelude::*;
|
||||
use bevy::{
|
||||
diagnostic::{FrameTimeDiagnosticsPlugin, LogDiagnosticsPlugin},
|
||||
prelude::*,
|
||||
window::ExitCondition,
|
||||
};
|
||||
use rand::Rng;
|
||||
|
||||
/// pre-defined test configurations with name
|
||||
|
@ -183,7 +187,15 @@ fn main() {
|
|||
|
||||
App::new()
|
||||
.insert_resource(cfg)
|
||||
.add_plugins((MinimalPlugins, TransformPlugin))
|
||||
.add_plugins((
|
||||
DefaultPlugins.set(WindowPlugin {
|
||||
primary_window: None,
|
||||
exit_condition: ExitCondition::DontExit,
|
||||
..default()
|
||||
}),
|
||||
FrameTimeDiagnosticsPlugin,
|
||||
LogDiagnosticsPlugin::default(),
|
||||
))
|
||||
.add_systems(Startup, setup)
|
||||
// Updating transforms *must* be done before `PostUpdate`
|
||||
// or the hierarchy will momentarily be in an invalid state.
|
||||
|
|
Loading…
Reference in a new issue