These pages are auto-generated from self-documenting comments embedded in class files.
For more information on breve and steve, refer to the breve homepage.

Shape : CustomShape

This class is included as part of the file Shape.tz.
To use this class in a simulation, include the line "@use Shape."

Class description:

A CustomShape is a subclass of (Shape) which allows the user to construct an arbitrary convex shape by specifying the faces of the shape.

The shapes must conform to the following rules:

  • The point (0, 0, 0) must be on inside (not outside or on the surface of) the shape.
  • The shape must be convex.
  • The shape must be solid and sealed by the faces.

    If any of these conditions are not met, you will get errors and/or unexpected results.

  • Class methods:


    add-face with-vertex-list vertexList (list)

    Adds a face defined by the list of vectors in vertextList.


    finish-shape with-density theDensity (float)

    This method must be called after all of the faces are added to complete initialization of the shape. The density given here will effect the physical properties of the shape if physical simulation is used. A value of 1.0 is reasonable.

    If the shape specified is invalid (according to the constraints listed above), this method will trigger an error.


    Documentation created Sun Oct 7 19:13:03 2007