Class Disk

All Implemented Interfaces:
ISingleColorable, IGLRenderer, ISortableDraw

public class Disk extends Wireframeable implements ISingleColorable
  • Constructor Details

    • Disk

      public Disk()
      Initialize a Cylinder at the origin.
    • Disk

      public Disk(Coord3d position, float radiusInner, float radiusOuter, int slices, int loops, Color color)
      Initialize a cylinder with the given parameters.
    • Disk

      public Disk(Coord3d position, float radiusOuter, int slices, int loops, Color color)
  • Method Details

    • draw

      public void draw(IPainter painter)
      Description copied from class: Drawable
      Call OpenGL2 routines for rendering the object.
      Specified by:
      draw in interface IGLRenderer
      Specified by:
      draw in class Drawable
    • doDrawDisk

      protected void doDrawDisk(IPainter painter)
    • setData

      public void setData(Coord3d position, float radiusInner, float radiusOuter, int slices, int loops)
    • setPosition

      public void setPosition(Coord3d position)
    • setVolume

      public void setVolume(float radiusInner, float radiusOuter)
    • updateBounds

      public void updateBounds()
      Specified by:
      updateBounds in class Drawable
    • setSlicing

      public void setSlicing(int verticalWires, int horizontalWires)
    • setColor

      public void setColor(Color color)
      Description copied from interface: ISingleColorable
      Set the color.
      Specified by:
      setColor in interface ISingleColorable
      Parameters:
      color - the color
    • getColor

      public Color getColor()
      Description copied from interface: ISingleColorable
      Get the color.
      Specified by:
      getColor in interface ISingleColorable
      Returns:
      color the color.
    • applyGeometryTransform

      public void applyGeometryTransform(Transform transform)
      Specified by:
      applyGeometryTransform in class Drawable