Om  1.0.0
A universal framework for multimedia simulation
Public Member Functions | List of all members
om::engine::DefaultEngineContext Class Reference

A default engine context with the standard collection of systems. More...

#include <omEngineDefaultEngineContext.h>

Inheritance diagram for om::engine::DefaultEngineContext:
om::engine::base::EngineContext

Public Member Functions

 DefaultEngineContext ()
 Create a new empty default engine context with the default systems. More...
 
virtual ~DefaultEngineContext ()
 
graphics::GraphicsSystemgetGraphics ()
 Return a reference to the graphics system for this engine. More...
 
const graphics::GraphicsSystemgetGraphics () const
 Return a reference to the graphics system for this engine. More...
 
physics::PhysicsSystemgetPhysics ()
 Return a reference to the physics system for this engine. More...
 
const physics::PhysicsSystemgetPhysics () const
 Return a reference to the physics system for this engine. More...
 
sound::SoundSystemgetSound ()
 Return a reference to the sound system for this engine. More...
 
const sound::SoundSystemgetSound () const
 Return a reference to the sound system for this engine. More...
 
acoustics::AcousticSystemgetAcoustics ()
 Return a reference to the acoustics system for this engine. More...
 
const acoustics::AcousticSystemgetAcoustics () const
 Return a reference to the acoustics system for this engine. More...
 
- Public Member Functions inherited from om::engine::base::EngineContext
 EngineContext ()
 Create a new empty engine context with no systems, entities, or components. More...
 
virtual ~EngineContext ()
 Destroy an engine context, releasing all internally allocated data. More...
 
virtual void update (const Time &dt)
 Update the state of all systems in this engine for the specified time interval. More...
 
template<typename T >
Bool addComponent (T *component, ResourceID *componentID=((void *) 0))
 Add a component of a concete template type to the engine. More...
 
Bool addComponent (const ResourceType &type, void *componentData)
 Add an opaque component of the specified type to the engine. More...
 
Bool addComponent (const OpaqueResource &component)
 Add an opaque component to the engine. More...
 
template<typename T >
Bool removeComponent (T *component)
 Remove the specified component of the template type from the engine. More...
 
Bool removeComponent (const OpaqueResource &component)
 Remove an opaque component from the engine. More...
 
Bool removeComponent (const ResourceType &type, void *componentData)
 Remove an opaque component of the specified type from the engine. More...
 
void clearComponents ()
 Remove all components from the engine. More...
 
Size getComponentTypeCount () const
 Return the number of different component types that this engine context is processing. More...
 
template<typename T >
ComponentSet< T > newComponentType ()
 Return a pointer to the component manager for components with the specified type in this engine. More...
 
template<typename T >
ComponentSet< T > getComponentType () const
 Return a pointer to the component manager for components with the specified type in this engine. More...
 
Bool addConnection (const Connection *connection)
 Add a data flow connection to this engine so that it is processed during simulation updates. More...
 
Bool removeConnection (const Connection *connection)
 Remove a data flow connection from this engine so that it is no longer processed. More...
 
void clearConnections ()
 Clear all connections from this engine context. More...
 
Size getSystemCount () const
 Return the number of systems there are in this engine context. More...
 
EngineSystemgetSystem (Index systemIndex) const
 Return a pointer to the system in this engine context at the specified index. More...
 
Bool addSystem (EngineSystem *system)
 Add a system to this engine context. More...
 
Bool removeSystem (const EngineSystem *system)
 Remove the system in this engine with the given pointer. More...
 
void clearSystems ()
 Remove all systems from this engine. More...
 
Size getEventTypeCount () const
 Return the number of different event types that this engine context is processing. More...
 
template<typename ValueType >
EventManager< ValueType > * newEventType (const EventType &eventType)
 Return a pointer to the event manager for events with the specified type in this engine. More...
 
template<typename ValueType >
EventManager< ValueType > * getEventType (const EventType &eventType)
 Return a pointer to the event manager for events with the specified type in this engine. More...
 
template<typename ValueType >
const EventManager< ValueType > * getEventType (const EventType &eventType) const
 Return a const pointer to the event manager for events with the specified type in this engine. More...
 
template<typename ValueType >
Bool addEvent (const EventType &eventType, const Event< ValueType > &newEvent)
 Post a new event to the engine context. More...
 
template<typename ValueType >
Bool addEvent (const EventType &eventType, const ValueType &value, const OpaqueResource &target=OpaqueResource(), const OpaqueResource &sender=OpaqueResource(), const EngineSystem *systemSender=((void *) 0))
 Post a new event to the engine context with the specified type, value, and other parameters. More...
 
template<typename ValueType >
Bool addEvent (const EventType &eventType, const ValueType &value, const OpaqueResource &target, const OpaqueResource &sender, const EngineSystem *systemSender, const Time &eventTime)
 Post a new event to the engine context with the specified type, value, and other parameters. More...
 
void clearEventTypes ()
 Clear the managers for every type of event that this engine was previously handling. More...
 
const TimegetTime () const
 Return the current reference wall-clock time of the engine context. More...
 
void setTime (const Time &newTime)
 Set the current reference wall-clock time of the engine context. More...
 

Additional Inherited Members

- Static Public Attributes inherited from om::engine::base::EngineContext
static const EventType ADD_COMPONENT_EVENT
 A static event type object that represents a add component event type. More...
 
static const EventType REMOVE_COMPONENT_EVENT
 A static event type object that represents a remove component event type. More...
 

Detailed Description

A default engine context with the standard collection of systems.

Constructor & Destructor Documentation

om::engine::DefaultEngineContext::DefaultEngineContext ( )

Create a new empty default engine context with the default systems.

virtual om::engine::DefaultEngineContext::~DefaultEngineContext ( )
virtual

Member Function Documentation

graphics::GraphicsSystem& om::engine::DefaultEngineContext::getGraphics ( )
inline

Return a reference to the graphics system for this engine.

const graphics::GraphicsSystem& om::engine::DefaultEngineContext::getGraphics ( ) const
inline

Return a reference to the graphics system for this engine.

physics::PhysicsSystem& om::engine::DefaultEngineContext::getPhysics ( )
inline

Return a reference to the physics system for this engine.

const physics::PhysicsSystem& om::engine::DefaultEngineContext::getPhysics ( ) const
inline

Return a reference to the physics system for this engine.

sound::SoundSystem& om::engine::DefaultEngineContext::getSound ( )
inline

Return a reference to the sound system for this engine.

const sound::SoundSystem& om::engine::DefaultEngineContext::getSound ( ) const
inline

Return a reference to the sound system for this engine.

acoustics::AcousticSystem& om::engine::DefaultEngineContext::getAcoustics ( )
inline

Return a reference to the acoustics system for this engine.

const acoustics::AcousticSystem& om::engine::DefaultEngineContext::getAcoustics ( ) const
inline

Return a reference to the acoustics system for this engine.


The documentation for this class was generated from the following file: