Expand description
Some things to accelerate the iteration
Group
Group is a useful method to accelerate the query iteration.
Acceleration Principle
To make iteration more fast and more cache friendly, we can rearrange the ord
of items. Group rearranges all group owning components which are both exist in their
sparse set to the front of sparse set.
We classify the groups as 3 types by the owner of components storage.
Component storage can only be owned by one group
Full-Owning Group
Full-owning group owns 2 component storages as its name.It’s the fastest group type because its can rearrange these 2 component storages to make them aligned.
Partial-Owning Group
Partial-Owning only owns the first storage.It’s not faster than Full-Owning group but it can stil make iteration fast
Non-Owning Group
This group does not own any storage.It use an extra sparse set to record the entities owned by all storage.Although it’s the slowest group and it need more memory to accelerate the iteration,it sill fast than raw query iteration.
Re-exports
pub use full_owning::FullOwning;
pub use partial_owning::PartialOwning;
pub use non_owning::NonOwning;
Modules
Full-owning group and its Queryable impls
Non-owning group and its Queryable impls
Partial-owning group and its Queryable impls
Enums
Functions
A useful function to create FullOwning group
A useful function to create NonOwning group
A useful function to create PartialOwning group