AnimatLab  2
Test
BulletAnimatSim::BlSimulator Class Reference
+ Inheritance diagram for BulletAnimatSim::BlSimulator:
+ Collaboration diagram for BulletAnimatSim::BlSimulator:

Public Member Functions

virtual void AddFluidPlane (FluidPlane *lpPlane)
 
virtual void AngularCompliance (float fltVal, bool bUseScaling=true)
 
virtual void AngularDamping (float fltVal, bool bUseScaling=true)
 
virtual void AngularKineticLoss (float fltVal, bool bUseScaling=true)
 
btBroadphaseInterface * BroadPhase ()
 
void BulletStepFinished (btScalar timeStep)
 
btDefaultCollisionConfiguration * CollisionConfig ()
 
virtual void ConvertV1MeshFile (std::string strOriginalMeshFile, std::string strNewMeshFile, std::string strTexture)
 
btCollisionDispatcherDispatcher ()
 
btDiscreteDynamicsWorld * DynamicsWorld ()
 
virtual FluidPlane * FindFluidPlaneForDepth (float fltDepth)
 Searches the fluid planes starting at the lowest height and working its way up to find the first one that depth is under. This is the density we will use for hydrodynamics. More...
 
virtual void GenerateCollisionMeshFile (std::string strOriginalMeshFile, std::string strCollisionMeshFile, float fltScaleX, float fltScaleY, float fltScaleZ)
 Generates a collision mesh file. More...
 
virtual void GetPositionAndRotationFromD3DMatrix (float(&aryTransform)[4][4], CStdFPoint &vPos, CStdFPoint &vRot)
 
virtual void Gravity (float fltVal, bool bUseScaling=true)
 
virtual bool HasFluidPlane (FluidPlane *lpPlane)
 
virtual void Initialize (int argc, const char **argv)
 
virtual void LinearCompliance (float fltVal, bool bUseScaling=true)
 
virtual void LinearDamping (float fltVal, bool bUseScaling=true)
 
virtual void LinearKineticLoss (float fltVal, bool bUseScaling=true)
 
virtual void RemoveFluidPlane (FluidPlane *lpPlane)
 
virtual void Reset ()
 
virtual void ResetSimulation ()
 
btConstraintSolver * Solver ()
 
virtual void SortFluidPlanes ()
 
virtual void StabilityScale (float fltVal)
 

Protected Member Functions

virtual AnimatSim::Recording::SimulationRecorderCreateSimulationRecorder ()
 
void InitializeBullet (int argc, const char **argv)
 
void InitializeBulletViewer (int argc, const char **argv)
 
void SetSimulationStabilityParams ()
 
virtual void SimulateEnd ()
 
virtual void StepSimulation ()
 

Protected Attributes

std::list< FluidPlane * > m_aryFluidPlanes
 
bool m_bDrawDebug
 
osgbCollision::GLDebugDrawer m_dbgDraw
 
double m_dblTotalVortexStepTime
 
int m_iSubstepCallbackCount
 
btBroadphaseInterface * m_lpBroadPhase
 
btDefaultCollisionConfiguration * m_lpCollisionConfiguration
 
BlAnimatCollisionDispatcherm_lpDispatcher
 
btDiscreteDynamicsWorld * m_lpDynamicsWorld
 
btConstraintSolver * m_lpSolver
 
long m_lStepVortexTimeCount
 

Detailed Description

Definition at line 15 of file BlSimulator.h.

Member Function Documentation

FluidPlane * BulletAnimatSim::BlSimulator::FindFluidPlaneForDepth ( float  fltDepth)
virtual

Searches the fluid planes starting at the lowest height and working its way up to find the first one that depth is under. This is the density we will use for hydrodynamics.

Author
David Cofer
Date
10/20/2013
Parameters
fltDepthDepth to search for with the fluid plane.
Returns
null if it fails, else the found fluid plane for depth.

Definition at line 599 of file BlSimulator.cpp.

void BulletAnimatSim::BlSimulator::GenerateCollisionMeshFile ( std::string  strOriginalMeshFile,
std::string  strCollisionMeshFile,
float  fltScaleX,
float  fltScaleY,
float  fltScaleZ 
)
virtual

Generates a collision mesh file.

When we want to use a collision mesh then we need to create a new .osg file using the mesh created by the physics engine instead of the graphics one. The UI will call this method when the user sets a new mesh file or type so we can create the new file. It will load the graphics file, convert it usign the physics engine, and then save it back out. When loading the convex mesh we will use this new file instead of the original one.

Author
dcofer
Date
6/10/2011
Parameters
strOriginalMeshFileThe original mesh file.
strCollisionMeshFileThe new collision mesh file.

Definition at line 370 of file BlSimulator.cpp.


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