Skip to content

Reuse heap allocations in prepare_mesh_bind_groups#24643

Merged
alice-i-cecile merged 4 commits into
bevyengine:mainfrom
beicause:prepare_mesh_bind_groups-reuse-heap-allocation
Jun 17, 2026
Merged

Reuse heap allocations in prepare_mesh_bind_groups#24643
alice-i-cecile merged 4 commits into
bevyengine:mainfrom
beicause:prepare_mesh_bind_groups-reuse-heap-allocation

Conversation

@beicause

@beicause beicause commented Jun 17, 2026

Copy link
Copy Markdown
Member

Objective

Reuse MeshBindGroups heap allocations in prepare_mesh_bind_groups

Solution

Reuse heap memory from previously existing MeshBindGroups resource.

Also the lightmaps bind groups should be keyed by metadata slab id otherwise it should be a bug if using vertex compression + lightmap + webgl2

Testing

Examples still work

@alice-i-cecile alice-i-cecile added A-Rendering Drawing game state to the screen C-Performance A change motivated by improving speed, memory usage or compile times X-Uncontroversial This work is generally agreed upon D-Straightforward Simple bug fixes and API improvements, docs, test and examples labels Jun 17, 2026
@github-project-automation github-project-automation Bot moved this to Needs SME Triage in Rendering Jun 17, 2026
@alice-i-cecile alice-i-cecile added the S-Needs-Review Needs reviewer attention (from anyone!) to move forward label Jun 17, 2026

@kfc35 kfc35 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good

@kfc35 kfc35 added S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it and removed S-Needs-Review Needs reviewer attention (from anyone!) to move forward labels Jun 17, 2026
@alice-i-cecile alice-i-cecile added this pull request to the merge queue Jun 17, 2026
Merged via the queue into bevyengine:main with commit 0008fd9 Jun 17, 2026
40 checks passed
@github-project-automation github-project-automation Bot moved this from Needs SME Triage to Done in Rendering Jun 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-Rendering Drawing game state to the screen C-Performance A change motivated by improving speed, memory usage or compile times D-Straightforward Simple bug fixes and API improvements, docs, test and examples S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it X-Uncontroversial This work is generally agreed upon

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants