-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add many_materials stress test #17346
Add many_materials stress test #17346
Conversation
The generated |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested on Windows/Nvidia with no issues. Added a few non-blocking suggestions.
- Removed ground plane as it was unnecessary. - Adjusted camera position for a better view. - Reused mesh handle to improve performance. - Regenerated examples README using `cargo run -p build-templated-pages -- update examples`.
I've addressed the feedback in a new commit. Please take another look when you have time. Thanks! |
Re-tested with the changes. Looks good! |
|
||
// Cubes | ||
let mesh_handle = mesh_assets.add(Cuboid::from_size(Vec3::ONE)); | ||
for x in 0..n { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We might need to make this 3 dimensional if frustum culling interacts with this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
actually, nevermind, I didn't realize the camera was adjusted to fit everything on screen when I made that comment.
} | ||
} | ||
|
||
fn animate_materials( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It might be good to have a runtime toggle for this. Like pressing spacebar.
This way we can more easily confirm that it's the animation that is the issue and not rendering.
Objective
many_materials
to benchmark the rendering performance of many animated materials.Solution
examples/stress_tests/many_materials.rs
) that renders a grid of cubes with animated materials.-n
command-line argument (or--grid-size
). The default grid size is 10x10.Testing
Showcase
Click to view showcase