bones icon indicating copy to clipboard operation
bones copied to clipboard

Determine a better policy for resizing and pre-allocating component storage.

Open github-actions[bot] opened this issue 10 months ago • 0 comments

Right now we double the size of the storage every time we run out. It seems like we might be able to come up with a smarter policy. On top of that we should be able to create a type data for components ( see bones_framework::metadata_asset()` for example ) that lets you customize the resize and also pre-allocation strategy for the component. Right now we don't pre-allocate any memory, but that could be useful for components that know there will be a lot of them, such as bullets.


https://github.com/fishfolk/bones/blob/db6560fbcc29b791e7cb2149bbd85c0497d03430/framework_crates/bones_ecs/src/components/untyped.rs#L223-L230


This issue was generated by todo-issue based on a TODO comment in db6560fbcc29b791e7cb2149bbd85c0497d03430.

github-actions[bot] avatar Aug 22 '23 14:08 github-actions[bot]