geomerative
public class RContour extends RGeomElem
Modifier and Type | Field and Description |
---|---|
RPoint[] |
points
Array of RPoint objects holding the points of the contour.
|
int |
type |
Constructor and Description |
---|
RContour() |
RContour(RContour c) |
RContour(RPoint[] contourpoints)
Create a countour given an array of points.
|
Modifier and Type | Method and Description |
---|---|
void |
addClose() |
void |
addPoint(float x,
float y) |
void |
addPoint(RPoint p)
Use this method to add new points to the contour.
|
void |
addPoints(java.util.List morePoints)
Efficiently add a list of points to the contour.
|
void |
addPoints(RPoint[] morePoints)
Efficiently add an array of points to the contour.
|
boolean |
contains(RPoint p) |
int |
countPoints()
Use this method to count the number of points in the contour.
|
void |
draw(processing.core.PApplet g) |
void |
draw(processing.core.PGraphics g)
Use this method to draw the contour.
|
RPoint[] |
getHandles()
Use this to return the points of the contour.
|
RPoint[][] |
getHandlesInPaths() |
RPoint |
getPoint(float t) |
RPoint[] |
getPoints()
Use this to return the points of the contour.
|
RPoint[][] |
getPointsInPaths() |
RPoint |
getTangent(float t) |
RPoint[] |
getTangents() |
RPoint[][] |
getTangentsInPaths() |
int |
getType()
Use this method to get the type of element this is.
|
boolean |
isHole()
Use this method to know if the contour is a hole.
|
void |
print() |
RMesh |
toMesh() |
RPolygon |
toPolygon() |
RShape |
toShape() |
centerIn, centerIn, centerIn, contains, contains, containsBounds, containsHandles, draw, getArea, getBottomLeft, getBottomRight, getBounds, getBoundsPoints, getCenter, getCenteringTransf, getCenteringTransf, getCenteringTransf, getCentroid, getCurveLength, getCurveLengths, getHeight, getOrigHeight, getOrigWidth, getStyle, getTopLeft, getTopRight, getWidth, getX, getY, intersects, intersects, intersectsBounds, intersectsHandles, isIn, isIn, rotate, rotate, rotate, scale, scale, scale, scale, scale, scale, setAlpha, setAlpha, setAlpha, setFill, setFill, setFill, setFillAlpha, setFillAlpha, setName, setStroke, setStroke, setStroke, setStrokeAlpha, setStrokeAlpha, setStrokeCap, setStrokeJoin, setStrokeWeight, setStrokeWeight, setStyle, shear, skewX, skewY, transform, transform, transform, translate, translate
public int type
public RPoint[] points
public RContour(RPoint[] contourpoints)
contourpoints
- the points of the new contourpublic RContour()
public RContour(RContour c)
public int countPoints()
public void draw(processing.core.PGraphics g)
public void addPoint(RPoint p)
public void addPoint(float x, float y)
public void addPoints(RPoint[] morePoints)
public void addPoints(java.util.List morePoints)
public RPoint[] getHandles()
getHandles
in class RGeomElem
public RPoint[] getPoints()
public RPoint getTangent(float t)
getTangent
in class RGeomElem
public RPoint[] getTangents()
getTangents
in class RGeomElem
public RPoint[][] getPointsInPaths()
getPointsInPaths
in class RGeomElem
public RPoint[][] getHandlesInPaths()
getHandlesInPaths
in class RGeomElem
public RPoint[][] getTangentsInPaths()
getTangentsInPaths
in class RGeomElem
public boolean isHole()
public void addClose()
public RShape toShape() throws java.lang.RuntimeException
Geomerative by Ricard Marxer, http://www.ricardmarxer.com/geomerative/