|
Estella 0.113.0
A fast 2D and 3D game engine powered by WebAssembly and ECS
|
What a resource's content is, as a number that changes whenever it does. More...


Go to the source code of this file.
Namespaces | |
| namespace | esengine |
Functions | |
| u64 | esengine::nextRevision () |
| A revision no content has had before. Never 0, which reads as "none". | |
What a resource's content is, as a number that changes whenever it does.
A mesh, a material, a texture, a probe grid each carry a revision: taken from here when their content is made and again whenever it changes. A reader that keeps what it derived from one (the renderer's per-entity record of a draw) keeps the revision beside it and asks again only when the revision moved. One counter for every kind, so a revision is unique across them all: a released resource whose memory or slot a new one reuses is never taken for it.
The engine's components say the same of themselves with change stamps (Registry::changedSince); resources are not in the registry, so they say it here.
Definition in file Revision.hpp.