lt.monarch.chart.chart3D.engine
Class Shape3D.Polygon

java.lang.Object
  extended by lt.monarch.chart.chart3D.engine.Shape3D.Polygon
All Implemented Interfaces:
Shape3D.ProjectableShape<Projector3D>
Enclosing class:
Shape3D<ChartProjector extends Projector>

protected class Shape3D.Polygon
extends java.lang.Object
implements Shape3D.ProjectableShape<Projector3D>

Class for storing polygon coordinates


Field Summary
Modifier and Type Field and Description
protected  java.util.ArrayList<Point3D> list
           
 
Constructor Summary
Constructor and Description
Shape3D.Polygon()
           
Shape3D.Polygon(int minsize)
           
Shape3D.Polygon(Point3D[] point3D)
           
 
Method Summary
Modifier and Type Method and Description
 void addPoint(Point3D point)
           
 Shape3D.ProjectableShape<Projector3D> clone()
          Retrieves a clone of this shape.
 void dispose()
          Clears the object
 java.awt.Shape getShape()
          Returns the swing Shape
 void project(Projector3D projector)
          Projects all the points of the shape
 void transform(Transformation3D tf, double anchorX, double anchorY, double anchorZ)
          Transforms all the points of the shape
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

list

protected java.util.ArrayList<Point3D> list
Constructor Detail

Shape3D.Polygon

public Shape3D.Polygon()

Shape3D.Polygon

public Shape3D.Polygon(int minsize)

Shape3D.Polygon

public Shape3D.Polygon(Point3D[] point3D)
Method Detail

addPoint

public void addPoint(Point3D point)

project

public void project(Projector3D projector)
Description copied from interface: Shape3D.ProjectableShape
Projects all the points of the shape

Specified by:
project in interface Shape3D.ProjectableShape<Projector3D>
Parameters:
projector - projector

transform

public void transform(Transformation3D tf,
                      double anchorX,
                      double anchorY,
                      double anchorZ)
Description copied from interface: Shape3D.ProjectableShape
Transforms all the points of the shape

Specified by:
transform in interface Shape3D.ProjectableShape<Projector3D>
Parameters:
tf - transformation matrix
anchorX - x anchor point for transformation
anchorY - y anchor point for transformation

dispose

public void dispose()
Description copied from interface: Shape3D.ProjectableShape
Clears the object

Specified by:
dispose in interface Shape3D.ProjectableShape<Projector3D>

getShape

public java.awt.Shape getShape()
Description copied from interface: Shape3D.ProjectableShape
Returns the swing Shape

Specified by:
getShape in interface Shape3D.ProjectableShape<Projector3D>
Returns:
Java Swing Shape

clone

public Shape3D.ProjectableShape<Projector3D> clone()
Description copied from interface: Shape3D.ProjectableShape
Retrieves a clone of this shape.

Specified by:
clone in interface Shape3D.ProjectableShape<Projector3D>
Overrides:
clone in class java.lang.Object
Returns:
a clone