JavaCAD
Public Member Functions | List of all members
com.piro.bezier.BezierListProducer Class Reference
Inheritance diagram for com.piro.bezier.BezierListProducer:
Inheritance graph
[legend]
Collaboration diagram for com.piro.bezier.BezierListProducer:
Collaboration graph
[legend]

Public Member Functions

void startPath () throws ParseException
 
void movetoRel (float x, float y) throws ParseException
 
void movetoAbs (float x, float y) throws ParseException
 
void closePath () throws ParseException
 
void linetoRel (float x, float y) throws ParseException
 
void linetoAbs (float x, float y) throws ParseException
 
void linetoHorizontalRel (float x) throws ParseException
 
void linetoHorizontalAbs (float x) throws ParseException
 
void linetoVerticalRel (float y) throws ParseException
 
void linetoVerticalAbs (float y) throws ParseException
 
void curvetoCubicRel (float x1, float y1, float x2, float y2, float x, float y) throws ParseException
 
void curvetoCubicAbs (float x1, float y1, float x2, float y2, float x, float y) throws ParseException
 
void curvetoCubicSmoothRel (float x2, float y2, float x, float y) throws ParseException
 
void curvetoCubicSmoothAbs (float x2, float y2, float x, float y) throws ParseException
 
void curvetoQuadraticRel (float x1, float y1, float x, float y) throws ParseException
 
void curvetoQuadraticAbs (float x1, float y1, float x, float y) throws ParseException
 
void curvetoQuadraticSmoothRel (float x, float y)
 
void curvetoQuadraticSmoothAbs (float x, float y) throws ParseException
 
void arcRel (float rx, float ry, float xAxisRotation, boolean largeArcFlag, boolean sweepFlag, float x, float y) throws ParseException
 
void arcAbs (float rx, float ry, float xAxisRotation, boolean largeArcFlag, boolean sweepFlag, float x, float y) throws ParseException
 
void endPath () throws ParseException
 

Detailed Description

A handler class that generates an array of shorts and an array floats from parsing path data.

Author
Cameron McCormack
Version
Id
PathArrayProducer.java 475685 2006-11-16 11:16:05Z cam

Definition at line 30 of file BezierListProducer.java.

Member Function Documentation

◆ arcAbs()

void com.piro.bezier.BezierListProducer.arcAbs ( float  rx,
float  ry,
float  xAxisRotation,
boolean  largeArcFlag,
boolean  sweepFlag,
float  x,
float  y 
) throws ParseException

Invoked when an absolute elliptical arc command has been parsed.

Command : A

Parameters
rxthe X axis radius for the ellipse
rythe Y axis radius for the ellipse
xAxisRotationthe rotation angle in degrees for the ellipse's X-axis relative to the X-axis
largeArcFlagthe value of the large-arc-flag
sweepFlagthe value of the sweep-flag
xthe absolute x coordinate for the end point
ythe absolute y coordinate for the end point
Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 220 of file BezierListProducer.java.

◆ arcRel()

void com.piro.bezier.BezierListProducer.arcRel ( float  rx,
float  ry,
float  xAxisRotation,
boolean  largeArcFlag,
boolean  sweepFlag,
float  x,
float  y 
) throws ParseException

Invoked when a relative elliptical arc command has been parsed.

Command : a

Parameters
rxthe X axis radius for the ellipse
rythe Y axis radius for the ellipse
xAxisRotationthe rotation angle in degrees for the ellipse's X-axis relative to the X-axis
largeArcFlagthe value of the large-arc-flag
sweepFlagthe value of the sweep-flag
xthe relative x coordinate for the end point
ythe relative y coordinate for the end point
Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 212 of file BezierListProducer.java.

◆ closePath()

void com.piro.bezier.BezierListProducer.closePath ( ) throws ParseException

Invoked when a closepath has been parsed.

Command : z | Z

Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 57 of file BezierListProducer.java.

Referenced by com.piro.bezier.BezierPath.parsePathList().

◆ curvetoCubicAbs()

void com.piro.bezier.BezierListProducer.curvetoCubicAbs ( float  x1,
float  y1,
float  x2,
float  y2,
float  x,
float  y 
) throws ParseException

Invoked when an absolute cubic bezier curve command has been parsed.

Command : C

Parameters
x1the absolute x coordinate for the first control point
y1the absolute y coordinate for the first control point
x2the absolute x coordinate for the second control point
y2the absolute y coordinate for the second control point
xthe absolute x coordinate for the end point
ythe absolute y coordinate for the end point
Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 117 of file BezierListProducer.java.

References com.piro.bezier.Bezier.getLength(), com.piro.bezier.BezierHistory.setLastKnot(), com.piro.bezier.BezierHistory.setLastPoint(), com.piro.bezier.Vector2.x, and com.piro.bezier.Vector2.y.

Referenced by com.piro.bezier.BezierListProducer.curvetoCubicRel(), and com.piro.bezier.BezierPath.parsePathList().

Here is the call graph for this function:

◆ curvetoCubicRel()

void com.piro.bezier.BezierListProducer.curvetoCubicRel ( float  x1,
float  y1,
float  x2,
float  y2,
float  x,
float  y 
) throws ParseException

Invoked when a relative cubic bezier curve command has been parsed.

Command : c

Parameters
x1the relative x coordinate for the first control point
y1the relative y coordinate for the first control point
x2the relative x coordinate for the second control point
y2the relative y coordinate for the second control point
xthe relative x coordinate for the end point
ythe relative y coordinate for the end point
Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 105 of file BezierListProducer.java.

References com.piro.bezier.BezierListProducer.curvetoCubicAbs(), com.piro.bezier.Vector2.x, and com.piro.bezier.Vector2.y.

Referenced by com.piro.bezier.BezierPath.parsePathList().

Here is the call graph for this function:

◆ curvetoCubicSmoothAbs()

void com.piro.bezier.BezierListProducer.curvetoCubicSmoothAbs ( float  x2,
float  y2,
float  x,
float  y 
) throws ParseException

Invoked when an absolute smooth cubic bezier curve command has been parsed. The first control point is assumed to be the reflection of the second control point on the previous command relative to the current point.

Command : S

Parameters
x2the absolute x coordinate for the second control point
y2the absolute y coordinate for the second control point
xthe absolute x coordinate for the end point
ythe absolute y coordinate for the end point
Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 145 of file BezierListProducer.java.

References com.piro.bezier.Bezier.getLength(), com.piro.bezier.BezierHistory.setLastKnot(), com.piro.bezier.BezierHistory.setLastPoint(), com.piro.bezier.Vector2.x, and com.piro.bezier.Vector2.y.

Referenced by com.piro.bezier.BezierListProducer.curvetoCubicSmoothRel(), and com.piro.bezier.BezierPath.parsePathList().

Here is the call graph for this function:

◆ curvetoCubicSmoothRel()

void com.piro.bezier.BezierListProducer.curvetoCubicSmoothRel ( float  x2,
float  y2,
float  x,
float  y 
) throws ParseException

Invoked when a relative smooth cubic bezier curve command has been parsed. The first control point is assumed to be the reflection of the second control point on the previous command relative to the current point.

Command : s

Parameters
x2the relative x coordinate for the second control point
y2the relative y coordinate for the second control point
xthe relative x coordinate for the end point
ythe relative y coordinate for the end point
Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 136 of file BezierListProducer.java.

References com.piro.bezier.BezierListProducer.curvetoCubicSmoothAbs(), com.piro.bezier.Vector2.x, and com.piro.bezier.Vector2.y.

Referenced by com.piro.bezier.BezierPath.parsePathList().

Here is the call graph for this function:

◆ curvetoQuadraticAbs()

void com.piro.bezier.BezierListProducer.curvetoQuadraticAbs ( float  x1,
float  y1,
float  x,
float  y 
) throws ParseException

Invoked when an absolute quadratic bezier curve command has been parsed.

Command : Q

Parameters
x1the absolute x coordinate for the control point
y1the absolute y coordinate for the control point
xthe absolute x coordinate for the end point
ythe absolute x coordinate for the end point
Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 180 of file BezierListProducer.java.

References com.piro.bezier.Bezier.getLength(), com.piro.bezier.BezierHistory.setLastKnot(), com.piro.bezier.BezierHistory.setLastPoint(), com.piro.bezier.Vector2.x, and com.piro.bezier.Vector2.y.

Referenced by com.piro.bezier.BezierListProducer.curvetoQuadraticRel(), com.piro.bezier.BezierListProducer.curvetoQuadraticSmoothAbs(), and com.piro.bezier.BezierPath.parsePathList().

Here is the call graph for this function:

◆ curvetoQuadraticRel()

void com.piro.bezier.BezierListProducer.curvetoQuadraticRel ( float  x1,
float  y1,
float  x,
float  y 
) throws ParseException

Invoked when a relative quadratic bezier curve command has been parsed.

Command : q

Parameters
x1the relative x coordinate for the control point
y1the relative y coordinate for the control point
xthe relative x coordinate for the end point
ythe relative x coordinate for the end point
Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 171 of file BezierListProducer.java.

References com.piro.bezier.BezierListProducer.curvetoQuadraticAbs(), com.piro.bezier.Vector2.x, and com.piro.bezier.Vector2.y.

Here is the call graph for this function:

◆ curvetoQuadraticSmoothAbs()

void com.piro.bezier.BezierListProducer.curvetoQuadraticSmoothAbs ( float  x,
float  y 
) throws ParseException

Invoked when an absolute smooth quadratic bezier curve command has been parsed. The control point is assumed to be the reflection of the control point on the previous command relative to the current point.

Command : T

Parameters
xthe absolute x coordinate for the end point
ythe absolute y coordinate for the end point
Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 205 of file BezierListProducer.java.

References com.piro.bezier.BezierListProducer.curvetoQuadraticAbs(), com.piro.bezier.Vector2.x, and com.piro.bezier.Vector2.y.

Referenced by com.piro.bezier.BezierListProducer.curvetoQuadraticSmoothRel(), and com.piro.bezier.BezierPath.parsePathList().

Here is the call graph for this function:

◆ curvetoQuadraticSmoothRel()

void com.piro.bezier.BezierListProducer.curvetoQuadraticSmoothRel ( float  x,
float  y 
)

Invoked when a relative smooth quadratic bezier curve command has been parsed. The control point is assumed to be the reflection of the control point on the previous command relative to the current point.

Command : t

Parameters
xthe relative x coordinate for the end point
ythe relative y coordinate for the end point
Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 197 of file BezierListProducer.java.

References com.piro.bezier.BezierListProducer.curvetoQuadraticSmoothAbs(), com.piro.bezier.Vector2.x, and com.piro.bezier.Vector2.y.

Referenced by com.piro.bezier.BezierPath.parsePathList().

Here is the call graph for this function:

◆ endPath()

void com.piro.bezier.BezierListProducer.endPath ( ) throws ParseException

Invoked when the path ends.

Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 228 of file BezierListProducer.java.

References com.piro.bezier.BezierHistory.setLastKnot(), com.piro.bezier.BezierHistory.setLastPoint(), com.piro.bezier.Vector2.x, and com.piro.bezier.Vector2.y.

Here is the call graph for this function:

◆ linetoAbs()

void com.piro.bezier.BezierListProducer.linetoAbs ( float  x,
float  y 
) throws ParseException

Invoked when an absolute line command has been parsed.

Command : L

Parameters
xthe absolute x coordinate for the end point
ythe absolute y coordinate for the end point
Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 70 of file BezierListProducer.java.

References com.piro.bezier.Bezier.getLength(), com.piro.bezier.BezierHistory.setLastKnot(), com.piro.bezier.BezierHistory.setLastPoint(), com.piro.bezier.Vector2.x, and com.piro.bezier.Vector2.y.

Referenced by com.piro.bezier.BezierListProducer.linetoHorizontalAbs(), com.piro.bezier.BezierListProducer.linetoHorizontalRel(), com.piro.bezier.BezierListProducer.linetoRel(), com.piro.bezier.BezierListProducer.linetoVerticalAbs(), com.piro.bezier.BezierListProducer.linetoVerticalRel(), and com.piro.bezier.BezierPath.parsePathList().

Here is the call graph for this function:

◆ linetoHorizontalAbs()

void com.piro.bezier.BezierListProducer.linetoHorizontalAbs ( float  x) throws ParseException

Invoked when an horizontal absolute line command has been parsed.

Command : H

Parameters
xthe absolute X coordinate of the end point
Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 90 of file BezierListProducer.java.

References com.piro.bezier.BezierListProducer.linetoAbs(), and com.piro.bezier.Vector2.y.

Referenced by com.piro.bezier.BezierPath.parsePathList().

Here is the call graph for this function:

◆ linetoHorizontalRel()

void com.piro.bezier.BezierListProducer.linetoHorizontalRel ( float  x) throws ParseException

Invoked when an horizontal relative line command has been parsed.

Command : h

Parameters
xthe relative X coordinate of the end point
Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 85 of file BezierListProducer.java.

References com.piro.bezier.BezierListProducer.linetoAbs(), com.piro.bezier.Vector2.x, and com.piro.bezier.Vector2.y.

Referenced by com.piro.bezier.BezierPath.parsePathList().

Here is the call graph for this function:

◆ linetoRel()

void com.piro.bezier.BezierListProducer.linetoRel ( float  x,
float  y 
) throws ParseException

Invoked when a relative line command has been parsed.

Command : l

Parameters
xthe relative x coordinates for the end point
ythe relative y coordinates for the end point
Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 62 of file BezierListProducer.java.

References com.piro.bezier.BezierListProducer.linetoAbs(), com.piro.bezier.Vector2.x, and com.piro.bezier.Vector2.y.

Referenced by com.piro.bezier.BezierPath.parsePathList().

Here is the call graph for this function:

◆ linetoVerticalAbs()

void com.piro.bezier.BezierListProducer.linetoVerticalAbs ( float  y) throws ParseException

Invoked when a vertical absolute line command has been parsed.

Command : V

Parameters
ythe absolute Y coordinate of the end point
Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 100 of file BezierListProducer.java.

References com.piro.bezier.BezierListProducer.linetoAbs(), and com.piro.bezier.Vector2.x.

Referenced by com.piro.bezier.BezierPath.parsePathList().

Here is the call graph for this function:

◆ linetoVerticalRel()

void com.piro.bezier.BezierListProducer.linetoVerticalRel ( float  y) throws ParseException

Invoked when a vertical relative line command has been parsed.

Command : v

Parameters
ythe relative Y coordinate of the end point
Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 95 of file BezierListProducer.java.

References com.piro.bezier.BezierListProducer.linetoAbs(), com.piro.bezier.Vector2.x, and com.piro.bezier.Vector2.y.

Here is the call graph for this function:

◆ movetoAbs()

void com.piro.bezier.BezierListProducer.movetoAbs ( float  x,
float  y 
) throws ParseException

Invoked when an absolute moveto command has been parsed.

Command : M

Parameters
xthe absolute x coordinate for the end point
ythe absolute y coordinate for the end point
Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 52 of file BezierListProducer.java.

References com.piro.bezier.BezierHistory.setLastPoint().

Referenced by com.piro.bezier.BezierListProducer.movetoRel(), and com.piro.bezier.BezierPath.parsePathList().

Here is the call graph for this function:

◆ movetoRel()

void com.piro.bezier.BezierListProducer.movetoRel ( float  x,
float  y 
) throws ParseException

Invoked when a relative moveto command has been parsed.

Command : m

Parameters
xthe relative x coordinate for the end point
ythe relative y coordinate for the end point
Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 44 of file BezierListProducer.java.

References com.piro.bezier.BezierListProducer.movetoAbs(), com.piro.bezier.Vector2.x, and com.piro.bezier.Vector2.y.

Referenced by com.piro.bezier.BezierPath.parsePathList().

Here is the call graph for this function:

◆ startPath()

void com.piro.bezier.BezierListProducer.startPath ( ) throws ParseException

Invoked when the path starts.

Exceptions
ParseExceptionif an error occured while processing the path

Implements com.piro.bezier.PathHandler.

Definition at line 38 of file BezierListProducer.java.


The documentation for this class was generated from the following file: