|
Emini Physics Engine 1.3.5a API Documentation | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectat.emini.physics2D.Shape
at.emini.physics2D.MultiShape
public class MultiShape
The multishape contains several shapes. It is an extension of the standard shape that is treated accordingly by the rest of the code.
Field Summary | |
---|---|
protected int[] |
mAxesStartIndices
Start indices for the unique axes for each shape in the common axes vector. |
protected Shape[] |
mShapes
List of shapes the shape consists of |
protected int[] |
mVertexStartIndices
Start indices for the vertices for each shape in the common vertex vector. |
Fields inherited from class at.emini.physics2D.Shape |
---|
MAX_MASS_FX, mCcentroid, mElasticityFX, mFrictionFX, mUserData, mVertices |
Constructor Summary | |
---|---|
MultiShape(MultiShape other)
Copy Constructor. |
|
MultiShape(java.util.Vector shapes)
Constructor. |
Method Summary | |
---|---|
Shape |
getShape(int index)
Returns the subshape at a given index. |
int |
getShapeCount()
Returns the number of subshapes. |
protected void |
initShapeMembers(java.util.Vector shapes)
Sets up the shape vectors. |
static MultiShape |
loadShape(PhysicsFileReader reader,
UserData userData,
java.util.Vector stdShapes)
Loads a multi shape from a stream. |
Methods inherited from class at.emini.physics2D.Shape |
---|
correctCentroid, createCircle, createRectangle, createRegularPolygon, getAreaFX, getBoundingRadius, getBoundingRadiusFX, getBoundingRadiusSquare, getCorners, getElasticityFX, getFrictionFX, getId, getMass, getMassFX, getUserData, getVerticesFX, loadShape, setElasticity, setElasticityFX, setFriction, setFrictionFX, setMass, setMassFX, setUserData, updateInternals |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected Shape[] mShapes
protected int[] mVertexStartIndices
protected int[] mAxesStartIndices
Constructor Detail |
---|
public MultiShape(java.util.Vector shapes)
shapes
- a vector of shapes that the multi shape consists ofpublic MultiShape(MultiShape other)
Method Detail |
---|
protected void initShapeMembers(java.util.Vector shapes)
shapes
- public Shape getShape(int index)
index
- the index of the subshape.
public int getShapeCount()
public static MultiShape loadShape(PhysicsFileReader reader, UserData userData, java.util.Vector stdShapes)
reader
- a physics file reader.
|
Emini Physics Engine 1.3.5a API Documentation | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |