HE_Mesh
5.1.0
|
Public Member Functions | |
abstract void | draw (PGraphics g) |
abstract void | draw (PApplet g) |
void | draw () |
abstract RPoint | getPoint (float t) |
abstract RPoint | getTangent (float t) |
abstract RPoint[] | getHandles () |
abstract RPoint[] | getPoints () |
abstract RPoint[] | getTangents () |
abstract RPoint[][] | getHandlesInPaths () |
abstract RPoint[][] | getPointsInPaths () |
abstract RPoint[][] | getTangentsInPaths () |
abstract boolean | contains (RPoint p) |
abstract int | getType () |
abstract RShape | toShape () |
void | print () |
void | setFill (boolean _fill) |
void | setFill (int _fillColor) |
void | setFill (String str) |
void | setStroke (boolean _stroke) |
void | setStroke (int _strokeColor) |
void | setStroke (String str) |
void | setStrokeWeight (float value) |
void | setStrokeWeight (String str) |
void | setStrokeCap (String str) |
void | setStrokeJoin (String str) |
void | setStrokeAlpha (int opacity) |
void | setStrokeAlpha (String str) |
void | setFillAlpha (int opacity) |
void | setFillAlpha (String str) |
void | setAlpha (float opacity) |
void | setAlpha (int opacity) |
void | setAlpha (String str) |
RStyle | getStyle () |
void | setStyle (RStyle s) |
void | setName (String str) |
float[] | getCurveLengths () |
float | getCurveLength () |
RPolygon | toPolygon () |
RMesh | toMesh () |
void | transform (RMatrix m) |
void | transform (float x, float y, float w, float h) |
boolean | isIn (PGraphics g) |
boolean | isIn (PApplet g) |
RMatrix | getCenteringTransf (PGraphics g) throws RuntimeException |
RMatrix | getCenteringTransf (PGraphics g, float margin) throws RuntimeException |
void | centerIn (PGraphics g) |
void | centerIn (PGraphics g, float margin) |
void | centerIn (PGraphics g, float margin, float sclDamping, float trnsDamping) throws RuntimeException |
void | rotate (float angle) |
void | scale (float sx, float sy) |
void | scale (float s) |
Public Attributes | |
float | width |
float | height |
String | name = "" |
Static Public Attributes | |
static final int | SHAPE = 0 |
static final int | SUBSHAPE = 1 |
static final int | COMMAND = 2 |
static final int | POLYGON = 3 |
static final int | CONTOUR = 4 |
static final int | MESH = 5 |
static final int | TRISTRIP = 6 |
static final int | GROUP = 7 |
static final int | UNKNOWN = 8 |
Protected Member Functions | |
void | saveContext (PGraphics g) |
void | saveContext (PApplet p) |
void | saveContext () |
void | restoreContext (PGraphics g) |
void | restoreContext (PApplet p) |
void | restoreContext () |
void | setContext (PGraphics g) |
void | setContext (PApplet p) |
void | setContext () |
void | setStyle (RGeomElem p) |
void | setStyle (String styleString) |
void | calculateCurveLengths () |
void | updateOrigParams () |
Protected Attributes | |
float[] | lenCurves |
float | lenCurve = -1F |
RStyle | style = new RStyle() |
Related Functions | |
(Note that these are not member functions.) | |
boolean | contains (RGeomElem shp) |
boolean | containsBounds (RGeomElem shp) |
boolean | containsHandles (RGeomElem shp) |
boolean | contains (RPoint[] ps) |
boolean | intersects (RGeomElem shp) |
boolean | intersectsBounds (RGeomElem shp) |
boolean | intersectsHandles (RGeomElem shp) |
boolean | intersects (RPoint[] ps) |
void | transform (float x, float y, float w, float h, boolean keepAspectRatio) |
RRectangle | getBounds () |
RPoint[] | getBoundsPoints () |
RPoint | getTopLeft () |
RPoint | getTopRight () |
RPoint | getBottomLeft () |
RPoint | getBottomRight () |
float | getX () |
float | getY () |
float | getOrigHeight () |
float | getOrigWidth () |
float | getWidth () |
float | getHeight () |
RPoint | getCenter () |
RPoint | getCentroid () |
float | getArea () |
RMatrix | getCenteringTransf (PGraphics g, float margin, float sclDamping, float trnsDamping) throws RuntimeException |
void | translate (float tx, float ty) |
void | translate (RPoint t) |
void | rotate (float angle, float vx, float vy) |
void | rotate (float angle, RPoint v) |
void | scale (float sx, float sy, RPoint p) |
void | scale (float sx, float sy, float x, float y) |
void | scale (float s, RPoint p) |
void | scale (float s, float x, float y) |
void | skewX (float angle) |
void | skewY (float angle) |
void | shear (float shx, float shy) |
RGeomElem is an interface to any geometric element that can be drawn and transformed, such as shapes, polygons or meshes.
|
protected |
void geomerative.RGeomElem.centerIn | ( | PGraphics | g | ) |
void geomerative.RGeomElem.centerIn | ( | PGraphics | g, |
float | margin | ||
) |
void geomerative.RGeomElem.centerIn | ( | PGraphics | g, |
float | margin, | ||
float | sclDamping, | ||
float | trnsDamping | ||
) | throws RuntimeException |
|
abstract |
|
abstract |
|
abstract |
void geomerative.RGeomElem.draw | ( | ) |
RMatrix geomerative.RGeomElem.getCenteringTransf | ( | PGraphics | g | ) | throws RuntimeException |
RMatrix geomerative.RGeomElem.getCenteringTransf | ( | PGraphics | g, |
float | margin | ||
) | throws RuntimeException |
float geomerative.RGeomElem.getCurveLength | ( | ) |
Use this to return the length of the curve. getCurveLength
float [] geomerative.RGeomElem.getCurveLengths | ( | ) |
Use this to return arclengths of each command on the curve. getCurveLength
|
abstract |
|
abstract |
|
abstract |
|
abstract |
|
abstract |
RStyle geomerative.RGeomElem.getStyle | ( | ) |
|
abstract |
|
abstract |
|
abstract |
|
abstract |
boolean geomerative.RGeomElem.isIn | ( | PGraphics | g | ) |
Use this method to know if the shape is inside a graphics object. This might be useful if we want to delete objects that go offscreen. RShape_isIn Geometry
g | the graphics object |
boolean geomerative.RGeomElem.isIn | ( | PApplet | g | ) |
void geomerative.RGeomElem.print | ( | ) |
|
protected |
|
protected |
|
protected |
void geomerative.RGeomElem.rotate | ( | float | angle | ) |
|
protected |
|
protected |
|
protected |
void geomerative.RGeomElem.scale | ( | float | sx, |
float | sy | ||
) |
void geomerative.RGeomElem.scale | ( | float | s | ) |
void geomerative.RGeomElem.setAlpha | ( | float | opacity | ) |
void geomerative.RGeomElem.setAlpha | ( | int | opacity | ) |
void geomerative.RGeomElem.setAlpha | ( | String | str | ) |
|
protected |
|
protected |
|
protected |
void geomerative.RGeomElem.setFill | ( | boolean | _fill | ) |
void geomerative.RGeomElem.setFill | ( | int | _fillColor | ) |
void geomerative.RGeomElem.setFill | ( | String | str | ) |
void geomerative.RGeomElem.setFillAlpha | ( | int | opacity | ) |
void geomerative.RGeomElem.setFillAlpha | ( | String | str | ) |
void geomerative.RGeomElem.setName | ( | String | str | ) |
void geomerative.RGeomElem.setStroke | ( | boolean | _stroke | ) |
void geomerative.RGeomElem.setStroke | ( | int | _strokeColor | ) |
void geomerative.RGeomElem.setStroke | ( | String | str | ) |
void geomerative.RGeomElem.setStrokeAlpha | ( | int | opacity | ) |
void geomerative.RGeomElem.setStrokeAlpha | ( | String | str | ) |
void geomerative.RGeomElem.setStrokeCap | ( | String | str | ) |
void geomerative.RGeomElem.setStrokeJoin | ( | String | str | ) |
void geomerative.RGeomElem.setStrokeWeight | ( | float | value | ) |
void geomerative.RGeomElem.setStrokeWeight | ( | String | str | ) |
void geomerative.RGeomElem.setStyle | ( | RStyle | s | ) |
|
protected |
|
protected |
RMesh geomerative.RGeomElem.toMesh | ( | ) |
RPolygon geomerative.RGeomElem.toPolygon | ( | ) |
|
abstract |
void geomerative.RGeomElem.transform | ( | RMatrix | m | ) |
void geomerative.RGeomElem.transform | ( | float | x, |
float | y, | ||
float | w, | ||
float | h | ||
) |
|
protected |
|
related |
Use this method to test if the shape contains all the points of another shape. contains
|
related |
Use this method to test if the shape contains an array of points. contains
|
related |
Use this method to test if the shape contains the bounding box of another shape. contains
|
related |
Use this method to test if the shape contains the handles of another shape. This method is faster than contains(), but the results might not be perfect. contains
|
related |
Use this method to get the area of an element. RGroup_getArea
|
related |
Use this method to get the bottom left position of the element. getX ( ) ( ) ( ) ( ) ( ) ( )
|
related |
Use this method to get the bottom right position of the element. getX ( ) ( ) ( ) ( ) ( ) ( )
|
related |
Use this method to get the bounding box of the element. getBounds
|
related |
Use this method to get the points of the bounding box of the element. getBounds
|
related |
Use this method to get the center point of the element. RGroup_getCenter
|
related |
Use this method to get the transformation matrix in order to fit and center the element on the canvas. Scaling and translation damping parameters are available, in order to create animations. RGeomElem_getCenteringTransf
g | the canvas to which to fit and center the path |
margin | the margin to take into account when fitting |
sclDamping | a value from 0 to 1. The damping coefficient for the scale, if the value is 0, then no scaling is applied. |
trnsDamping | a value from 0 to 1. The damping coefficient for the translation, if the value is 0, then no translation is applied. ( ) |
|
related |
Use this method to get the centroid of the element. RGroup_getCentroid
|
related |
Use this method to get the height of the element. getHeight
|
related |
Use this method to get the original height of the element. getOrigHeight
|
related |
Use this method to get the original width of the element. getOrigWidth
|
related |
Use this method to get the top left position of the element. getX ( ) ( ) ( ) ( ) ( ) ( )
|
related |
Use this method to get the top right position of the element. getX ( ) ( ) ( ) ( ) ( ) ( )
|
related |
Use this method to get the width of the element. getWidth
|
related |
Use this method to get the x (left side) position of the element. getX
|
related |
Use this method to get the y position of the element. getY
|
related |
Use this method to test if the shape intersects another shape. intersects
|
related |
Use this method to test if the shape intersects an array of points. intersects
|
related |
Use this method to test if the shape intersects the bounding box of another shape. intersects
|
related |
Use this method to test if the shape intersects the handles of another shape. This method is faster than intersects(), but the results might not be perfect. intersects
|
related |
Apply a rotation to the element, given an angle and optionally a rotation center. RPoint_rotate Geometry
angle | the angle of rotation to be applied |
vx | the x coordinate of the center of rotation |
vy | the y coordinate of the center of rotation ( ) ( ) ( ) |
|
related |
Apply a rotation to the element, given an angle and optionally a rotation center. RPoint_rotate Geometry
angle | the angle of rotation to be applied |
v | the position vector of the center of rotation ( ) ( ) ( ) |
|
related |
Apply a scale to the element, given scaling factors and optionally a scaling center. RPoint_scale Geometry
sx | the scaling coefficient over the x axis |
sy | the scaling coefficient over the y axis |
p | the position vector of the center of the scaling ( ) ( ) ( ) |
|
related |
Apply a scale to the element, given scaling factors and optionally a scaling center. RPoint_scale Geometry
sx | the scaling coefficient over the x axis |
sy | the scaling coefficient over the y axis |
x | x coordinate of the position vector of the center of the scaling |
y | y coordinate of the position vector of the center of the scaling ( ) ( ) ( ) |
|
related |
Apply a scale to the element, given scaling factors and optionally a scaling center. RPoint_scale Geometry
s | the scaling coefficient for a uniform scaling |
p | the position vector of the center of the scaling ( ) ( ) ( ) |
|
related |
Apply a scale to the element, given scaling factors and optionally a scaling center. RPoint_scale Geometry
s | the scaling coefficient for a uniform scaling |
x | x coordinate of the position vector of the center of the scaling |
y | y coordinate of the position vector of the center of the scaling ( ) ( ) ( ) |
|
related |
Apply a shear to the element, given shearing factors RMatrix_translate
shx | x coordinate shearing |
shy | y coordinate shearing Geometry ( ) ( ) ( ) |
|
related |
Apply a horizontal skew to the element, given skewing angle RMatrix_skewing
angle | skewing angle Geometry ( ) ( ) ( ) |
|
related |
Apply a vertical skew to the element, given skewing angle RMatrix_skewing
angle | skewing angle Geometry ( ) ( ) ( ) |
|
related |
Transform the geometric object to fit in a rectangle defined by the parameters passed. getBounds ( )
|
related |
Apply a translation to the element, given translation coordinates. RGeomElem_translate Geometry
tx | the coefficient of x translation |
ty | the coefficient of y translation ( ) ( ) ( ) |
|
related |
Apply a translation to the element, given a point. RGeomElem_translate Geometry
t | the translation vector to be applied ( ) ( ) ( ) |
|
static |
|
static |
|
static |
float geomerative.RGeomElem.height |
Shape document height.
|
protected |
|
protected |
|
static |
String geomerative.RGeomElem.name = "" |
|
static |
|
static |
|
static |
|
static |
|
static |
float geomerative.RGeomElem.width |
Shape document width.