public class OpenSimParser
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static java.io.File |
DEFAULT_GEOMETRY_PATH |
Constructor and Description |
---|
OpenSimParser(java.io.File osimFile) |
OpenSimParser(java.io.File file,
java.io.File geometryPath,
OpenSimObjectFactoryStore factories)
Creates a new parser
|
Modifier and Type | Method and Description |
---|---|
MechModel |
createModel() |
MechModel |
createModel(MechModel mech)
Populates the provided model, creating one if it doesn't exist
|
RenderableComponentList<RigidBody> |
getBodySet(MechModel mech)
Return the list of rigid bodies.
|
ModelComponentMap |
getComponentMap()
Returns the ModelComponentMap for the most recently created model,
or {#code null} if no model has been created yet.
|
ComponentList<ModelComponent> |
getConstraintSet(MechModel mech)
Return the list of constraints.
|
java.util.ArrayList<ForceComponent> |
getForceComponents(MechModel mech) |
RenderableComponentList<ModelComponent> |
getForceSet(MechModel mech)
Return the force set list.
|
java.io.File |
getGeometryPath() |
java.util.ArrayList<PointSpringBase> |
getMusclesAndSprings(MechModel mech) |
java.util.ArrayList<RigidBody> |
getWrapObjects(MechModel mech) |
void |
load() |
void |
setGeometryPath(java.io.File path) |
void |
setWrapObjectsVisible(MechModel mech,
boolean visible) |
void |
zeroExcitations(MechModel mech) |
public OpenSimParser(java.io.File file, java.io.File geometryPath, OpenSimObjectFactoryStore factories)
file
- file to parsegeometryPath
- path to search for geometriesfactories
- factory storage for generating OpenSim objects from filepublic OpenSimParser(java.io.File osimFile)
public void load()
public void setGeometryPath(java.io.File path)
public java.io.File getGeometryPath()
public MechModel createModel(MechModel mech)
mech
- mechanical modelpublic MechModel createModel()
public ModelComponentMap getComponentMap()
public java.util.ArrayList<ForceComponent> getForceComponents(MechModel mech)
public java.util.ArrayList<PointSpringBase> getMusclesAndSprings(MechModel mech)
public RenderableComponentList<RigidBody> getBodySet(MechModel mech)
public RenderableComponentList<ModelComponent> getForceSet(MechModel mech)
public ComponentList<ModelComponent> getConstraintSet(MechModel mech)
public void zeroExcitations(MechModel mech)
public void setWrapObjectsVisible(MechModel mech, boolean visible)