gramods
|
The Updateable class defines an interface for objects that may be updated, for example each execution frame. More...
#include <Updateable.hh>
Classes | |
struct | Impl |
Public Types | |
typedef std::chrono::steady_clock | clock |
Public Member Functions | |
Updateable (int priority=0) | |
Configures the Updateable properties to the specified priority. More... | |
virtual void | update (clock::time_point t, size_t frame)=0 |
Called by updateAll to make the object up-to-date. More... | |
Static Public Member Functions | |
static void | updateAll (clock::time_point t=clock::now(), std::optional< size_t > frame=std::nullopt) |
Updates all currently instanciated updateable objects. More... | |
The Updateable class defines an interface for objects that may be updated, for example each execution frame.
This may be an animator or a network connection.
gramods::gmCore::Updateable::Updateable | ( | int | priority = 0 | ) |
Configures the Updateable properties to the specified priority.
Upon call to updateAll all instances of Updateable will be called in turn based on their priority. Highest priority will be called first and lowest last. Instances with the same priority will be called in the order of instantiation.
|
pure virtual |
Called by updateAll to make the object up-to-date.
Implemented in gramods::gmGraphics::TransitionCoordinatesMapper::Impl, gramods::gmGraphics::CubeSceneRenderer::Impl, gramods::gmGraphics::VelocityViewpoint, gramods::gmGraphics::OsgRenderer, gramods::gmCore::OpenVR::Impl, gramods::gmTrack::SampleCollector, gramods::gmGraphics::ImageTexture, gramods::gmSound::Multilateration, and gramods::gmGraphics::TrackedTransform::Impl.
|
static |
Updates all currently instanciated updateable objects.