Vector Graphics
A Simplified Approach with Examples in Java |
Prof. David Bernstein
|
Computer Science Department |
bernstdh@jmu.edu |
setPaperColor(name:String)
setInkColor(name:String)
setPenWidth(pixels:int)
setLineType(name:String)
moveTo(p:Point)
drawTo(p:Point)
Point
Class:
getCoordinate(i:int):double
Point
objects
PiecewiseLinearCurve
PiecewiseLinearCurve
and
Polygon
are identical.
LineSegment
can be modified
to work the same way.
Point
.
Feature
Point
in the
Feature
by a scalarPoint
in the
Feature
Point
:
Point
objectsPoint
?
Point
Point
:
Point
objectPoint
objectsPoint
?
Point
objects,
the component-by-component minimum and maximumPoint
object or another RectangularHull
objectPoint
?
Point
objectsFeature
:
getRectangularHull():RectangularHull
LineSegment
,
PiecewiseLinearCurve
, etc...) may be able to
do it more efficiently