Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Reallocate materials when they change. (bevyengine#17979)
PR bevyengine#17898 regressed this, causing much of bevyengine#17970. This commit fixes the issue by freeing and reallocating materials in the `MaterialBindGroupAllocator` on change. Note that more efficiency is possible, but I opted for the simple approach because (1) we should fix this bug ASAP; (2) I'd like bevyengine#17965 to land first, because that unlocks the biggest potential optimization, which is not recreating the bind group if it isn't necessary to do so.
- Loading branch information