Class PhysicsEngineFactory

java.lang.Object
fr.phylisiumstudio.bullet.PhysicsEngineFactory
All Implemented Interfaces:
IPhysicsEngineFactory<com.bulletphysics.dynamics.DiscreteDynamicsWorld,com.bulletphysics.dynamics.RigidBody,com.bulletphysics.collision.shapes.CollisionShape,com.bulletphysics.linearmath.Transform>

public class PhysicsEngineFactory extends Object implements IPhysicsEngineFactory<com.bulletphysics.dynamics.DiscreteDynamicsWorld,com.bulletphysics.dynamics.RigidBody,com.bulletphysics.collision.shapes.CollisionShape,com.bulletphysics.linearmath.Transform>
  • Constructor Details

    • PhysicsEngineFactory

      public PhysicsEngineFactory()
  • Method Details

    • createWorld

      public com.bulletphysics.dynamics.DiscreteDynamicsWorld createWorld()
      Description copied from interface: IPhysicsEngineFactory
      Create a new dynamics world
      Specified by:
      createWorld in interface IPhysicsEngineFactory<com.bulletphysics.dynamics.DiscreteDynamicsWorld,com.bulletphysics.dynamics.RigidBody,com.bulletphysics.collision.shapes.CollisionShape,com.bulletphysics.linearmath.Transform>
      Returns:
      the new dynamics world
    • createRigidBody

      public com.bulletphysics.dynamics.RigidBody createRigidBody(float mass, com.bulletphysics.collision.shapes.CollisionShape shape, com.bulletphysics.linearmath.Transform transform)
      Description copied from interface: IPhysicsEngineFactory
      Create a new rigid body
      Specified by:
      createRigidBody in interface IPhysicsEngineFactory<com.bulletphysics.dynamics.DiscreteDynamicsWorld,com.bulletphysics.dynamics.RigidBody,com.bulletphysics.collision.shapes.CollisionShape,com.bulletphysics.linearmath.Transform>
      Parameters:
      mass - the mass of the rigid body
      shape - the shape of the rigid body
      transform - the transform of the rigid body
      Returns:
      the new rigid body