Skip to content
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

Batch draw calls? #159

Open
SUPERCILEX opened this issue Apr 29, 2022 · 5 comments
Open

Batch draw calls? #159

SUPERCILEX opened this issue Apr 29, 2022 · 5 comments

Comments

@SUPERCILEX
Copy link

See bevyengine/bevy#3763 (comment). I'm not sure if this is actually an issue.

@louiidev
Copy link

Performance seems like an issue for this crate currently, I'm drawing the same thing multiple times and notice a big dip in fps, batching should help a lot

@rparrett
Copy link
Contributor

rparrett commented Nov 2, 2023

With Bevy 0.12 getting automatic batching, it might be possible to rework bevy_prototype_lyon so that it can benefit from that. As things stand now, this doesn't help us.

We would need to find some way to reuse generated mesh assets so that shape entities with the same attributes would point at the same mesh asset. I'm guessing that this is more complicated than it sounds -- we need to make sure Bevy's asset lifecycle continues to work. i.e. assets that are no longer referenced in the world get dropped.

@seivan
Copy link

seivan commented Jun 4, 2024

Is this fixed? Since Bevy should now group material and meshes together?

@rparrett
Copy link
Contributor

rparrett commented Jun 4, 2024

As far as I know, no. Last time I looked, Bevy only batches when the mesh handle is identical and unless I missed something, that hasn't changed. My previous message should still generally be true

@seivan
Copy link

seivan commented Jun 4, 2024

As far as I know, no. Last time I looked, Bevy only batches when the mesh handle is identical and unless I missed something, that hasn't changed. My previous message should still generally be true

That actually makes sense. It should be like that. So if the handle is the same for the mesh and material, it will batch? That’s perfect.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants