public class RigidMesh extends MeshComponent implements PullController.Pullable, Collidable
Collidable.DefaultCollidable
ModelComponent.NavpanelVisibility
Modifier and Type | Field and Description |
---|---|
static boolean |
DEFAULT_PHYSICAL |
static PropertyList |
myProps |
enforceUniqueCompositeNames, enforceUniqueNames, myNumber, NULL_OBJ, useCompactPathNames
Default, Deformable, RigidBody, Self
ARTICULATED, SIMULATING
TRANSLUCENT, TWO_DIMENSIONAL
Constructor and Description |
---|
RigidMesh() |
RigidMesh(MeshBase mesh,
java.lang.String fileName,
AffineTransform3dBase X) |
RigidMesh(java.lang.String name) |
Modifier and Type | Method and Description |
---|---|
void |
applyForce(java.lang.Object orig,
Vector3d force)
Given the supplied force origin info and a force vector,
apply the force (typically sets an external force)
|
RigidMesh |
copy(int flags,
java.util.Map<ModelComponent,ModelComponent> copyMap) |
CollisionData |
createCollisionData() |
PropertyList |
getAllPropertyInfo()
Returns a list giving static information about all properties exported by
this object.
|
PolygonalMesh |
getCollisionMesh() |
double |
getMass() |
java.lang.Object |
getOriginData(MouseRayEvent ray)
Constructs force origin storage data given a mouse ray
(e.g.
|
Point3d |
getOriginPoint(java.lang.Object data)
Determines the world-coordinate point to which force will
be applied (used for determining magnitude of force)
|
double |
getPointRenderRadius() |
RigidBody |
getRigidBody() |
void |
getSelection(java.util.LinkedList<java.lang.Object> list,
int qid)
Append to
list the component (or components) associated with
the qid -th selection query issued by this component's render
method. |
boolean |
isCollidable() |
boolean |
isPhysical() |
boolean |
isPullable() |
int |
numSelectionQueriesNeeded()
If this selectable manages its own selection (by issuing selection
queries within its
render method), then this method should
return the maximum number of selection queries that will be
required. |
void |
render(GLRenderer renderer,
RenderProps props,
int flags) |
void |
setPhysical(boolean set) |
createRenderProps, getMesh, getVertex, numVertices, prerender, render, scaleDistance, scaleMass, setDefaultValues, setMesh, setMesh, setMesh, transformGeometry, transformGeometry, transformGeometry, updateBounds, updatePosition, updateSlavePos
getRenderHints, getRenderProps, isSelectable, setRenderProps, updateRenderProps
checkFlag, checkName, checkNameUniqueness, clearFlag, clone, connectToHierarchy, createTempFlag, disconnectFromHierarchy, getChildren, getGrandParent, getHardReferences, getName, getNameRange, getNavpanelVisibility, getNavpanelVisibility, getNumber, getParent, getProperty, getSoftReferences, hasChildren, hasState, isFixed, isMarked, isSelected, isWritable, makeValidName, makeValidName, notifyParentOfChange, postscan, printReferences, recursivelyContained, recursivelyContains, removeTempFlag, scan, setFixed, setFlag, setMarked, setName, setNavpanelVisibility, setNavpanelVisibility, setNumber, setParent, setSelected, updateReferences, write
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
connectToHierarchy, disconnectFromHierarchy, getHardReferences, getName, getNavpanelVisibility, getNumber, getParent, getSoftReferences, hasState, isFixed, isMarked, isSelected, notifyParentOfChange, postscan, scan, setFixed, setMarked, setName, setNumber, setParent, setSelected, updateReferences
getProperty
getChildren, hasChildren
isWritable, write
public static boolean DEFAULT_PHYSICAL
public static PropertyList myProps
public RigidMesh()
public RigidMesh(java.lang.String name)
public RigidMesh(MeshBase mesh, java.lang.String fileName, AffineTransform3dBase X)
public PropertyList getAllPropertyInfo()
HasProperties
getAllPropertyInfo
in interface HasProperties
getAllPropertyInfo
in class MeshComponent
public boolean isPhysical()
public void setPhysical(boolean set)
public void render(GLRenderer renderer, RenderProps props, int flags)
render
in class MeshComponent
public RigidBody getRigidBody()
public RigidMesh copy(int flags, java.util.Map<ModelComponent,ModelComponent> copyMap)
copy
in class MeshComponent
public boolean isPullable()
isPullable
in interface PullController.Pullable
public java.lang.Object getOriginData(MouseRayEvent ray)
PullController.Pullable
getOriginData
in interface PullController.Pullable
public Point3d getOriginPoint(java.lang.Object data)
PullController.Pullable
getOriginPoint
in interface PullController.Pullable
public double getPointRenderRadius()
getPointRenderRadius
in interface PullController.Pullable
public void applyForce(java.lang.Object orig, Vector3d force)
PullController.Pullable
applyForce
in interface PullController.Pullable
public int numSelectionQueriesNeeded()
GLSelectable
render
method), then this method should
return the maximum number of selection queries that will be
required. Otherwise, this method should return -1.numSelectionQueriesNeeded
in interface GLSelectable
numSelectionQueriesNeeded
in class RenderableComponentBase
public void getSelection(java.util.LinkedList<java.lang.Object> list, int qid)
GLSelectable
list
the component (or components) associated with
the qid
-th selection query issued by this component's render
method. This will only be called if this component manages its own
selection (i.e., the number nums
returned by GLSelectable.numSelectionQueriesNeeded()
is positive), and qid
will in
turn be a number between 0 and nums
-1.getSelection
in interface GLSelectable
getSelection
in class RenderableComponentBase
list
- selected objects are appended to the end of this listqid
- index of the selection querypublic CollisionData createCollisionData()
createCollisionData
in interface Collidable
public PolygonalMesh getCollisionMesh()
public double getMass()
getMass
in interface Collidable
public boolean isCollidable()
isCollidable
in interface Collidable