blaze.dynamics.Space
Authors:
Blaze team, see AUTHORS file
Maintainers:
Mason Green (zzzzrrr)
License:
zlib/png license
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
arising from the use of this software.
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute it
freely, subject to the following restrictions:
1. The origin of this software must not be misrepresented; you must not
claim that you wrote the original software. If you use this software
in a product, an acknowledgment in the product documentation would be
appreciated but is not required.
2. Altered source versions must be plainly marked as such, and must not be
misrepresented as being the original software.
3. This notice may not be removed or altered from any source
distribution.
$(DDOC_MODULE_MEMBERS
alias
ArbiterHash
;
class
Space
;
- int
iterations
;
- int
contactPersistence
;
- Vector2D
force
;
- Vector2D
masslessForce
;
- Number
damping
;
- static int
stamp
;
- RigidBody[]
bodies
;
- GeometricShape[]
shapes
;
- static ArbiterHash
contactDict
;
- Arbiter dictionary
- static Arbiter[]
arbiterPool
;
- static Contact[]
contactPool
;
- For debugging purposes (allows demo to draw contact points)
- RigidBody
staticBody
;
- BroadPhase
broadPhase
;
- bool
collectStats
;
- Counter
broadphaseCounter
;
- Counter
narrowphaseCounter
;
- Counter
sortCounter
;
- this(int numIterations = 20, int damping = 1);
- void
step
(double dt);
- Main simulation
step
- void
narrowPhase
(Arbiter arbiter, double dt);
- bool
scrubArbiter
(Arbiter arbiter);
- Remove arbiters greater than contact persistance (~3 is good
)
- GeometricShape
addStaticShape
(GeometricShape shape);
- Add static shape to simulation
- void
removeStaticShape
(GeometricShape shape);
- Remove shape from simulation
- void
addRigidBody
(RigidBody rBody);
- Add rigid body to simulation
- void
removeRigidBody
(RigidBody rBody);
- Remove rigid body from simulation
|