All Implemented Interfaces:
PoseChangeListener, EventListener

public class ODESphere extends ODEBody
Wrapper for a ODE4J Sphere.
  • Constructor Details

    • ODESphere

      public ODESphere()
    • ODESphere

      public ODESphere(String name)
  • Method Details

    • getComponents

      public void getComponents(List<JPanel> list)
      Description copied from class: Pose
      Build a Swing Component that represents this Node.
      Overrides:
      getComponents in class ODEBody
      Parameters:
      list - the list to add components to.
    • getRadius

      public double getRadius()
    • setRadius

      public void setRadius(double radius)
    • toJSON

      public org.json.JSONObject toJSON()
      Description copied from class: Node
      Serialize this node and its children to a JSON object and its children. Classes that override this method should call super.toJSON() first, then add to the object returned.
      Overrides:
      toJSON in class ODEBody
      Returns:
      the JSON object.
    • fromJSON

      public void fromJSON(org.json.JSONObject json)
      Description copied from class: Node
      Deserialize this node and its children from a JSON object and its children. Classes that override this method should call super.fromJSON(). When they do it will trigger the creation of child nodes. The child nodes will then call their own fromJSON() methods.
      Overrides:
      fromJSON in class ODEBody
      Parameters:
      json - the JSON object to read from.