artisynth.core.femmodels
Class SkinCollisionData

java.lang.Object
  extended by artisynth.core.mechmodels.DeformableCollisionDataBase
      extended by artisynth.core.femmodels.SkinCollisionData
All Implemented Interfaces:
CollisionData, DeformableCollisionData

public class SkinCollisionData
extends DeformableCollisionDataBase


Constructor Summary
SkinCollisionData(SkinMesh smc)
           
 
Method Summary
 boolean allowCollision(ContactPenetratingPoint cpp, boolean isVertex, CollisionData otherData)
          Allow a collision between this object and the supplied 'other'.
 DeformableContactConstraint createContact(Vertex3d... vtxs)
           
 Collidable getComponent()
          Returns the component involved in the collision
 int getVertexDependencies(Vertex3d vtx, java.util.ArrayList<Point> pointDeps, VectorNd pntWgts, java.util.ArrayList<Frame> frameDeps, VectorNd frameWgts)
          Determines the set of points that a vertex's position is dependent upon, along with their weights (assuming a linear relationship)
 void markMasters(Vertex3d vtx, boolean marked)
          Mark the master dynamic components of vertex vtx as being "used"
 int numActiveMasters(ContactPenetratingPoint cpp, boolean isVertex)
           
 int numActiveMasters(EdgeEdgeContact eec, boolean isFirst)
           
 int numActiveUnmarkedMasters(Vertex3d vtx)
          Count the number of "free" master components for vertex vtx.
 
Methods inherited from class artisynth.core.mechmodels.DeformableCollisionDataBase
addBilateralConstraints, addConstraintInfo, addContact, addFrictionConstraints, allowCollision, clearContactActivity, clearContactData, contactsHaveChanged, getAuxState, getBilateralImpulses, getBilateralInfo, getBilateralSizes, getCollisionTol, getContact, getContact, getFriction, getInitialAuxState, getMesh, hasActiveContact, hasActiveContact, hasActiveContacts, maxFrictionConstraintSets, notifyContactsChanged, numActiveContacts, reduceConstraints, removeInactiveContacts, setAuxState, setBilateralImpulses, setFriction, setPenetrationTol, skipAuxState, updateFrictionConstraints, zeroImpulses
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SkinCollisionData

public SkinCollisionData(SkinMesh smc)
Method Detail

createContact

public DeformableContactConstraint createContact(Vertex3d... vtxs)

allowCollision

public boolean allowCollision(ContactPenetratingPoint cpp,
                              boolean isVertex,
                              CollisionData otherData)
Description copied from interface: DeformableCollisionData
Allow a collision between this object and the supplied 'other'. You should not allow if the objects are attached at any of the involved points.

Parameters:
cpp - the contact-penetrating point involved between the two.
isVertex - if true, checks if we can allow collision based on the vertex, otherwise if we are checking the face
otherData - the other collision object involved
Returns:
true if the collision is allowed, false otherwise

numActiveMasters

public int numActiveMasters(ContactPenetratingPoint cpp,
                            boolean isVertex)

numActiveMasters

public int numActiveMasters(EdgeEdgeContact eec,
                            boolean isFirst)

getVertexDependencies

public int getVertexDependencies(Vertex3d vtx,
                                 java.util.ArrayList<Point> pointDeps,
                                 VectorNd pntWgts,
                                 java.util.ArrayList<Frame> frameDeps,
                                 VectorNd frameWgts)
Description copied from interface: DeformableCollisionData
Determines the set of points that a vertex's position is dependent upon, along with their weights (assuming a linear relationship)

Parameters:
vtx - the vertex belonging to this collision data
pointDeps - list of points that is filled
pntWgts - weights associated with the returned points
frameDeps - list of frames that is filled
frameWgts - weights associated with the returned frames
Returns:
the number of dependent points

getComponent

public Collidable getComponent()
Description copied from interface: CollisionData
Returns the component involved in the collision


markMasters

public void markMasters(Vertex3d vtx,
                        boolean marked)
Description copied from interface: CollisionData
Mark the master dynamic components of vertex vtx as being "used"


numActiveUnmarkedMasters

public int numActiveUnmarkedMasters(Vertex3d vtx)
Description copied from interface: CollisionData
Count the number of "free" master components for vertex vtx. Used for determining whether or not a collision should be allowed.