#include <S2_api.h>
Public Member Functions | |
UniverseAPI () | |
~UniverseAPI () | |
Universe Creation and Destruction | |
bool | BigBang (unsigned int max_obj=S2_UNIVERSE_DEFAULT_MAX_OBJ) |
void | BigCrunch () |
System creation and destruction | |
[OSCAR] These methods will encapsulate the complexity of creating/destroying Systems and adding/removing S2::Objects to them. | |
SystemAPI * | CreateSystemAPI () |
void | DestroySystemAPI (SystemAPI *p_system) |
Object creation and destruction | |
[OSCAR] These methods will encapsulate the complexity of creating/destroying and adding/removing S2::Objects of any type/model. | |
ParticleAPI * | CreateParticleAPI (SystemAPI *p_sys=NULL) |
void | DestroyParticleAPI (ParticleAPI *p_particle) |
RigidAPI * | CreateRigidAPI (SystemAPI *p_sys=NULL) |
void | DestroyRigidAPI (RigidAPI *p_rigid) |
Simulation methods | |
void | Update (Real dt) |
Utility methods | |
void | Debug (S2::DebugStream &ds) |
Private Attributes | |
S2::Universe * | m_pUniverse |
Universe public API for Saphyre2. Offers user-level functionality for creating, running and querying an animated universe.
Factory of Animation Objects and Systems.
|
|
|
|
|
Initializes a Universe with a rigid maximum of max_obj animation objects. |
|
It's the end of the world as we know it... |
|
Creates a particle and adds it to the p_sys System if not NULL. Otherwise the object is considered uncoupled with any other object (it's a free object) |
|
Creates a rigid body and adds it to the p_sys System if not NULL. Otherwise the object is considered uncoupled with any other object (it's a free object) |
|
|
Prints some info about the Universe in the log file. |
|
|
|
|
|
Exactly that... and also frees the used memory, so don't try to use p_system after this call ok? |
|
Advances a timestep of dt for all the Objects currently simulated in this Universe. |
|
|