JOGL v2.6.0-rc-20250712
JOGL, High-Performance Graphics Binding for Java™ (public API).
com.jogamp.graph.curve.OutlineShape Class Reference

A Generic shape objects which is defined by a list of Outlines. More...

Inheritance diagram for com.jogamp.graph.curve.OutlineShape:
Collaboration diagram for com.jogamp.graph.curve.OutlineShape:

Classes

enum  VerticesState
 Outline's vertices have undefined state until transformed. More...
 

Public Member Functions

 OutlineShape ()
 Create a new Outline based Shape. More...
 
final int getAddedVerticeCount ()
 Return the number of newly added vertices during getTriangles(VerticesState) while transforming the outlines to VerticesState#QUADRATIC_NURBS and triangulation. More...
 
final float getSharpness ()
 Sharpness value, defaults to DEFAULT_SHARPNESS. More...
 
final void setSharpness (final float s)
 Sets sharpness, defaults to DEFAULT_SHARPNESS. More...
 
final void clear ()
 Clears all data and reset all states as if this instance was newly created. More...
 
final void clearCache ()
 Clears cached triangulated data, i.e. More...
 
final int getOutlineCount ()
 Returns the number of Outlines. More...
 
final int getVertexCount ()
 Returns the total vertex number of all Outlines. More...
 
final Winding getWindingOfLastOutline ()
 Compute the Winding of the getLastOutline() using the VectorUtil#area(ArrayList) function over all of its vertices. More...
 
final void setWindingOfLastOutline (final Winding enforced)
 Sets the enforced Winding of the getLastOutline(). More...
 
boolean isComplex ()
 Returns cached or computed result if at least one polyline of getOutline(int) is a complex shape, see Outline#isComplex(). More...
 
void setOverrideConvex (final boolean convex)
 Overrides isComplex() using the given value instead of computing via Outline#isComplex(). More...
 
void clearOverrideConvex ()
 Clears the isComplex() override done by setOverrideConvex(boolean). More...
 
final void addEmptyOutline ()
 Add a new empty Outline to the end of this shape's outline list. More...
 
final void addOutline (final Outline outline) throws NullPointerException
 Appends the Outline element to the end, ensuring a clean tail. More...
 
final void addOutline (final int position, final Outline outline) throws NullPointerException, IndexOutOfBoundsException
 Insert the Outline element at the given position. More...
 
final void addOutlineShape (final OutlineShape outlineShape) throws NullPointerException
 Insert the OutlineShape elements of type Outline, . More...
 
final void setOutline (final int position, final Outline outline) throws NullPointerException, IndexOutOfBoundsException
 Replaces the Outline element at the given position. More...
 
final Outline removeOutline (final int position) throws IndexOutOfBoundsException
 Removes the Outline element at the given position. More...
 
final Outline getLastOutline ()
 Get the last added outline to the list of outlines that define the shape. More...
 
final Outline getOutline (final int position) throws IndexOutOfBoundsException
 Returns the Outline at position @endiliteral.
More...
 
final void addVertex (final Vertex v)
 Adds a vertex to the last open outline to the shape's tail. More...
 
final void addVertex (final int position, final Vertex v)
 Adds a vertex to the last open outline to the shape at position @endiliteral.
More...
 
final void addVertex (final float x, final float y, final boolean onCurve)
 Add a 2D Vertex to the last open outline to the shape's tail. More...
 
final void addVertex (final int position, final float x, final float y, final boolean onCurve)
 Add a 2D Vertex to the last open outline to the shape at position. More...
 
final void addVertex (final float x, final float y, final float z, final boolean onCurve)
 Add a 3D Vertex to the last open outline to the shape's tail. More...
 
final void addVertex (final int position, final float x, final float y, final float z, final boolean onCurve)
 Add a 3D Vertex to the last open outline to the shape at position. More...
 
final void addVertex (final float[] coordsBuffer, final int offset, final int length, final boolean onCurve)
 Add a vertex to the last open outline to the shape's tail. More...
 
final void addVertex (final int position, final float[] coordsBuffer, final int offset, final int length, final boolean onCurve)
 Add a vertex to the last open outline to the shape at position. More...
 
final void closeLastOutline (final boolean closeTail)
 Closes the last outline in the shape. More...
 
void addPath (final Path2F path, final boolean connect)
 Append the given path geometry to this outline shape. More...
 
final void addPath (final Path2F.Iterator pathI, boolean connect)
 Add the given Path2F.Iterator to this outline shape. More...
 
void addPathRev (final Path2F path, final boolean connect)
 Append the given path geometry to this outline shape in reverse order. More...
 
final void addPathRev (final Path2F.Iterator pathI, boolean connect)
 Add the given Path2F.Iterator to this outline shape in reverse order. More...
 
final void moveTo (final float x, final float y, final float z)
 Start a new position for the next line segment at given point x/y (P1). More...
 
final void lineTo (final float x, final float y, final float z)
 Add a line segment, intersecting the last point and the given point x/y (P1). More...
 
final void quadTo (final float x1, final float y1, final float z1, final float x2, final float y2, final float z2)
 Add a quadratic curve segment, intersecting the last point and the second given point x2/y2 (P2). More...
 
final void cubicTo (final float x1, final float y1, final float z1, final float x2, final float y2, final float z2, final float x3, final float y3, final float z3)
 Add a cubic Bézier curve segment, intersecting the last point and the second given point x3/y3 (P3). More...
 
final void closePath ()
 Closes the current sub-path segment by drawing a straight line back to the coordinates of the last moveTo. More...
 
final VerticesState getOutlineState ()
 Return the outline's vertices state, OutlineShape.VerticesState. More...
 
final void setIsQuadraticNurbs ()
 Claim this outline's vertices are all OutlineShape.VerticesState#QUADRATIC_NURBS, hence no cubic transformations will be performed. More...
 
final ArrayList< VertexgetVertices ()
 Return list of concatenated vertices associated with all Outlines of this object. More...
 
final ArrayList< TrianglegetTriangles (final VerticesState destinationType)
 Triangulate the OutlineShape generating a list of triangles, while transformOutlines(VerticesState) beforehand. More...
 
final OutlineShape transform (final AffineTransform t)
 Return a transformed instance with all Outlines are copied and transformed. More...
 
final int compareTo (final OutlineShape other)
 Compare two outline shape's Bounding Box size. More...
 
final AABBox getBounds ()
 
final boolean equals (final Object obj)
 
final int hashCode ()
 
String toString ()
 
void print (final PrintStream out)
 

Static Public Member Functions

static void printPerf (final PrintStream out)
 

Static Public Attributes

static final float DEFAULT_SHARPNESS = 0.5f
 Initial getSharpness() value, which can be modified via setSharpness(float). More...
 

Detailed Description

A Generic shape objects which is defined by a list of Outlines.

This Shape can be transformed to triangulations. The list of triangles generated are render-able by a Region object. The triangulation produced by this Shape will define the closed region defined by the outlines.

One or more OutlineShape Object can be associated to a region this is left as a high-level representation of the Objects. For optimizations, flexibility requirements for future features.

Outline shape general Winding rules

Example to creating an Outline Shape:

   addVertex(...)
   addVertex(...)
   addVertex(...)
   addEmptyOutline()
   addVertex(...)
   addVertex(...)
   addVertex(...)

The above will create two outlines each with three vertices. By adding these two outlines to the OutlineShape, we are stating that the combination of the two outlines represent the shape.

To specify that the shape is curved at a region, the on-curve flag should be set to false for the vertex that is in the middle of the curved region (if the curved region is defined by 3 vertices (quadratic curve).

In case the curved region is defined by 4 or more vertices the middle vertices should both have the on-curve flag set to false.

Example:

   addVertex(0,0, true);
   addVertex(0,1, false);
   addVertex(1,1, false);
   addVertex(1,0, true);

<p<blockquote>‍

The above snippet defines a cubic nurbs curve where (0,1 and 1,1) do not belong to the final rendered shape.

Implementation Notes:

  • The first vertex of any outline belonging to the shape should be on-curve
  • Intersections between off-curved parts of the outline is not handled
See also
Outline
Region

Definition at line 123 of file OutlineShape.java.

Constructor & Destructor Documentation

◆ OutlineShape()

com.jogamp.graph.curve.OutlineShape.OutlineShape ( )

Create a new Outline based Shape.

Definition at line 187 of file OutlineShape.java.

Here is the caller graph for this function:

Member Function Documentation

◆ addEmptyOutline()

final void com.jogamp.graph.curve.OutlineShape.addEmptyOutline ( )

Add a new empty Outline to the end of this shape's outline list.

If the getLastOutline() is empty already, no new one will be added.

After a call to this function all new vertices added will belong to the new outline

Definition at line 331 of file OutlineShape.java.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ addOutline() [1/2]

final void com.jogamp.graph.curve.OutlineShape.addOutline ( final int  position,
final Outline  outline 
) throws NullPointerException, IndexOutOfBoundsException

Insert the Outline element at the given position.

If the position indicates the end of this list, a clean tail is ensured, no double empty Outlines are produced and a pre-existing empty outline will be replaced with the given one.

Parameters
positionof the added Outline
outlineOutline object to be added
Exceptions
NullPointerExceptionif the Outline element is null
IndexOutOfBoundsExceptionif position is out of range (position < 0 || position > getOutlineNumber())

Definition at line 363 of file OutlineShape.java.

Here is the call graph for this function:

◆ addOutline() [2/2]

final void com.jogamp.graph.curve.OutlineShape.addOutline ( final Outline  outline) throws NullPointerException

Appends the Outline element to the end, ensuring a clean tail.

A clean tail is ensured, no double empty Outlines are produced and a pre-existing empty outline will be replaced with the given one.

Parameters
outlineOutline object to be added
Exceptions
NullPointerExceptionif the Outline element is null

Definition at line 347 of file OutlineShape.java.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ addOutlineShape()

final void com.jogamp.graph.curve.OutlineShape.addOutlineShape ( final OutlineShape  outlineShape) throws NullPointerException

Insert the OutlineShape elements of type Outline, .

. at the end of this shape, using addOutline(Outline) for each element.

Closes the current last outline via closeLastOutline(boolean) before adding the new ones.

Parameters
outlineShapeOutlineShape elements to be added.
Exceptions
NullPointerExceptionif the OutlineShape is null
IndexOutOfBoundsExceptionif position is out of range (position < 0 || position > getOutlineNumber())

Definition at line 397 of file OutlineShape.java.

Here is the call graph for this function:

◆ addPath() [1/2]

void com.jogamp.graph.curve.OutlineShape.addPath ( final Path2F  path,
final boolean  connect 
)

Append the given path geometry to this outline shape.

The given path geometry should be Winding#CCW.

If the given path geometry is Winding#CW, use addPathRev(Path2F, boolean).

Parameters
paththe Path2F to append to this outline shape, should be Winding#CCW.
connectpass true to turn an initial moveTo segment into a lineTo segment to connect the new geometry to the existing path, otherwise pass false.
See also
Path2F::getWinding()

Definition at line 601 of file OutlineShape.java.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ addPath() [2/2]

final void com.jogamp.graph.curve.OutlineShape.addPath ( final Path2F.Iterator  pathI,
boolean  connect 
)

Add the given Path2F.Iterator to this outline shape.

The given path geometry should be Winding#CCW.

If the given path geometry is Winding#CW, use . pathI the Path2F.Iterator to append to this outline shape, should be Winding#CCW.

Parameters
connectpass true to turn an initial moveTo segment into a lineTo segment to connect the new geometry to the existing path, otherwise pass false.
See also
Path2F.Iterator::getWinding()

Definition at line 616 of file OutlineShape.java.

Here is the call graph for this function:

◆ addPathRev() [1/2]

void com.jogamp.graph.curve.OutlineShape.addPathRev ( final Path2F  path,
final boolean  connect 
)

Append the given path geometry to this outline shape in reverse order.

The given path geometry should be Winding#CW.

If the given path geometry is Winding#CCW, use addPath(Path2F, boolean).

Parameters
paththe Path2F to append to this outline shape, should be Winding#CW.
connectpass true to turn an initial moveTo segment into a lineTo segment to connect the new geometry to the existing path, otherwise pass false.

Definition at line 676 of file OutlineShape.java.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ addPathRev() [2/2]

final void com.jogamp.graph.curve.OutlineShape.addPathRev ( final Path2F.Iterator  pathI,
boolean  connect 
)

Add the given Path2F.Iterator to this outline shape in reverse order.

The given path geometry should be Winding#CW.

If the given path geometry is Winding#CCW, use . pathI the Path2F.Iterator to append to this outline shape, should be Winding#CW.

Parameters
connectpass true to turn an initial moveTo segment into a lineTo segment to connect the new geometry to the existing path, otherwise pass false.

Definition at line 690 of file OutlineShape.java.

Here is the call graph for this function:

◆ addVertex() [1/8]

final void com.jogamp.graph.curve.OutlineShape.addVertex ( final float  x,
final float  y,
final boolean  onCurve 
)

Add a 2D Vertex to the last open outline to the shape's tail.

The 2D vertex will be represented as Z=0.

Parameters
xthe x coordinate
ythe y coordniate
onCurveflag if this vertex is on the final curve or defines a curved region of the shape around this vertex.
See also
see winding rules

Definition at line 494 of file OutlineShape.java.

Here is the call graph for this function:

◆ addVertex() [2/8]

final void com.jogamp.graph.curve.OutlineShape.addVertex ( final float  x,
final float  y,
final float  z,
final boolean  onCurve 
)

Add a 3D Vertex to the last open outline to the shape's tail.

Parameters
xthe x coordinate
ythe y coordinate
zthe z coordinate
onCurveflag if this vertex is on the final curve or defines a curved region of the shape around this vertex.
See also
see winding rules

Definition at line 521 of file OutlineShape.java.

Here is the call graph for this function:

◆ addVertex() [3/8]

final void com.jogamp.graph.curve.OutlineShape.addVertex ( final float[]  coordsBuffer,
final int  offset,
final int  length,
final boolean  onCurve 
)

Add a vertex to the last open outline to the shape's tail.

The vertex is passed as a float array and its offset where its attributes are located. The attributes should be continuous (stride = 0). Attributes which value are not set (when length less than 3) are set implicitly to zero.

Parameters
coordsBufferthe coordinate array where the vertex attributes are to be picked from
offsetthe offset in the buffer to the x coordinate
lengththe number of attributes to pick from the buffer (maximum 3)
onCurveflag if this vertex is on the final curve or defines a curved region of the shape around this vertex.
See also
see winding rules

Definition at line 552 of file OutlineShape.java.

Here is the call graph for this function:

◆ addVertex() [4/8]

final void com.jogamp.graph.curve.OutlineShape.addVertex ( final int  position,
final float  x,
final float  y,
final boolean  onCurve 
)

Add a 2D Vertex to the last open outline to the shape at position.

The 2D vertex will be represented as Z=0.

Parameters
positionindex within the last open outline, at which the vertex will be added
xthe x coordinate
ythe y coordniate
onCurveflag if this vertex is on the final curve or defines a curved region of the shape around this vertex.
See also
see winding rules

Definition at line 508 of file OutlineShape.java.

Here is the call graph for this function:

◆ addVertex() [5/8]

final void com.jogamp.graph.curve.OutlineShape.addVertex ( final int  position,
final float  x,
final float  y,
final float  z,
final boolean  onCurve 
)

Add a 3D Vertex to the last open outline to the shape at position.

Parameters
positionindex within the last open outline, at which the vertex will be added
xthe x coordinate
ythe y coordniate
zthe z coordinate
onCurveflag if this vertex is on the final curve or defines a curved region of the shape around this vertex.
See also
see winding rules

Definition at line 535 of file OutlineShape.java.

Here is the call graph for this function:

◆ addVertex() [6/8]

final void com.jogamp.graph.curve.OutlineShape.addVertex ( final int  position,
final float[]  coordsBuffer,
final int  offset,
final int  length,
final boolean  onCurve 
)

Add a vertex to the last open outline to the shape at position.

The vertex is passed as a float array and its offset where its attributes are located. The attributes should be continuous (stride = 0). Attributes which value are not set (when length less than 3) are set implicitly to zero.

Parameters
positionindex within the last open outline, at which the vertex will be added
coordsBufferthe coordinate array where the vertex attributes are to be picked from
offsetthe offset in the buffer to the x coordinate
lengththe number of attributes to pick from the buffer (maximum 3)
onCurveflag if this vertex is on the final curve or defines a curved region of the shape around this vertex.
See also
see winding rules

Definition at line 570 of file OutlineShape.java.

Here is the call graph for this function:

◆ addVertex() [7/8]

final void com.jogamp.graph.curve.OutlineShape.addVertex ( final int  position,
final Vertex  v 
)

Adds a vertex to the last open outline to the shape at position @endiliteral.

Parameters
positionindex within the last open outline, at which the vertex will be added
vthe vertex to be added to the OutlineShape
See also
see winding rules

Definition at line 476 of file OutlineShape.java.

Here is the call graph for this function:

◆ addVertex() [8/8]

final void com.jogamp.graph.curve.OutlineShape.addVertex ( final Vertex  v)

Adds a vertex to the last open outline to the shape's tail.

Parameters
vthe vertex to be added to the OutlineShape
See also
see winding rules

Definition at line 459 of file OutlineShape.java.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ clear()

final void com.jogamp.graph.curve.OutlineShape.clear ( )

Clears all data and reset all states as if this instance was newly created.

Definition at line 225 of file OutlineShape.java.

Here is the call graph for this function:

◆ clearCache()

final void com.jogamp.graph.curve.OutlineShape.clearCache ( )

Clears cached triangulated data, i.e.

getTriangles(VerticesState) and getVertices().

Definition at line 242 of file OutlineShape.java.

Here is the caller graph for this function:

◆ clearOverrideConvex()

void com.jogamp.graph.curve.OutlineShape.clearOverrideConvex ( )

Clears the isComplex() override done by setOverrideConvex(boolean).

See also
setOverrideConvex(boolean)
isComplex()

Definition at line 318 of file OutlineShape.java.

◆ closeLastOutline()

final void com.jogamp.graph.curve.OutlineShape.closeLastOutline ( final boolean  closeTail)

Closes the last outline in the shape.

Checks whether the last vertex equals to the first of the last outline. If not equal, it either appends a copy of the first vertex or prepends a copy of the last vertex, depending on closeTail.

Parameters
closeTailif true, a copy of the first vertex will be appended, otherwise a copy of the last vertex will be prepended.

Definition at line 584 of file OutlineShape.java.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ closePath()

final void com.jogamp.graph.curve.OutlineShape.closePath ( )

Closes the current sub-path segment by drawing a straight line back to the coordinates of the last moveTo.

If the path is already closed then this method has no effect.

See also
Path2F::closePath()
addPath(com.jogamp.math.geom.plane.Path2F.Iterator, boolean)

Definition at line 819 of file OutlineShape.java.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ compareTo()

final int com.jogamp.graph.curve.OutlineShape.compareTo ( final OutlineShape  other)

Compare two outline shape's Bounding Box size.

See also
AABBox::getSize()
java.lang.Comparable::compareTo(java.lang.Object)

Definition at line 1120 of file OutlineShape.java.

Here is the call graph for this function:

◆ cubicTo()

final void com.jogamp.graph.curve.OutlineShape.cubicTo ( final float  x1,
final float  y1,
final float  z1,
final float  x2,
final float  y2,
final float  z2,
final float  x3,
final float  y3,
final float  z3 
)

Add a cubic Bézier curve segment, intersecting the last point and the second given point x3/y3 (P3).

Parameters
x1Bézier control point (P1)
y1Bézier control point (P1)
z1Bézier control point (P1)
x2Bézier control point (P2)
y2Bézier control point (P2)
z2Bézier control point (P2)
x3final interpolated control point (P3)
y3final interpolated control point (P3)
z3final interpolated control point (P3)
See also
Path2F::cubicTo(float, float, float, float, float, float)
addPath(com.jogamp.math.geom.plane.Path2F.Iterator, boolean)
see winding rules

Definition at line 808 of file OutlineShape.java.

Here is the call graph for this function:

◆ equals()

final boolean com.jogamp.graph.curve.OutlineShape.equals ( final Object  obj)
Parameters
objthe Object to compare this OutlineShape with
Returns
true if obj is an OutlineShape, not null, same outlineState, equal bounds and equal outlines in the same order

Definition at line 1153 of file OutlineShape.java.

Here is the call graph for this function:

◆ getAddedVerticeCount()

final int com.jogamp.graph.curve.OutlineShape.getAddedVerticeCount ( )

Return the number of newly added vertices during getTriangles(VerticesState) while transforming the outlines to VerticesState#QUADRATIC_NURBS and triangulation.

See also
setIsQuadraticNurbs()

Definition at line 209 of file OutlineShape.java.

Here is the caller graph for this function:

◆ getBounds()

final AABBox com.jogamp.graph.curve.OutlineShape.getBounds ( )

Definition at line 1140 of file OutlineShape.java.

Here is the caller graph for this function:

◆ getLastOutline()

final Outline com.jogamp.graph.curve.OutlineShape.getLastOutline ( )

Get the last added outline to the list of outlines that define the shape.

Returns
the last outline

Definition at line 441 of file OutlineShape.java.

Here is the caller graph for this function:

◆ getOutline()

final Outline com.jogamp.graph.curve.OutlineShape.getOutline ( final int  position) throws IndexOutOfBoundsException

Returns the Outline at position @endiliteral.

Exceptions
IndexOutOfBoundsExceptionif position is out of range (position < 0 || position >= getOutlineNumber())

Definition at line 449 of file OutlineShape.java.

Here is the caller graph for this function:

◆ getOutlineCount()

final int com.jogamp.graph.curve.OutlineShape.getOutlineCount ( )

Returns the number of Outlines.

Definition at line 249 of file OutlineShape.java.

Here is the caller graph for this function:

◆ getOutlineState()

final VerticesState com.jogamp.graph.curve.OutlineShape.getOutlineState ( )

Return the outline's vertices state, OutlineShape.VerticesState.

Definition at line 829 of file OutlineShape.java.

Here is the caller graph for this function:

◆ getSharpness()

final float com.jogamp.graph.curve.OutlineShape.getSharpness ( )

Sharpness value, defaults to DEFAULT_SHARPNESS.

Definition at line 214 of file OutlineShape.java.

◆ getTriangles()

final ArrayList< Triangle > com.jogamp.graph.curve.OutlineShape.getTriangles ( final VerticesState  destinationType)

Triangulate the OutlineShape generating a list of triangles, while transformOutlines(VerticesState) beforehand.

Triangles are cached until marked dirty.

Returns
an arraylist of triangles representing the filled region which is produced by the combination of the outlines

Definition at line 1059 of file OutlineShape.java.

Here is the caller graph for this function:

◆ getVertexCount()

final int com.jogamp.graph.curve.OutlineShape.getVertexCount ( )

Returns the total vertex number of all Outlines.

Definition at line 254 of file OutlineShape.java.

Here is the caller graph for this function:

◆ getVertices()

final ArrayList< Vertex > com.jogamp.graph.curve.OutlineShape.getVertices ( )

Return list of concatenated vertices associated with all Outlines of this object.

Vertices are cached until marked dirty.

Should always be called after getTriangles(VerticesState), since the latter will mark all cached vertices dirty!

Definition at line 1005 of file OutlineShape.java.

Here is the caller graph for this function:

◆ getWindingOfLastOutline()

final Winding com.jogamp.graph.curve.OutlineShape.getWindingOfLastOutline ( )

Compute the Winding of the getLastOutline() using the VectorUtil#area(ArrayList) function over all of its vertices.

Returns
Winding#CCW or Winding#CW

Definition at line 266 of file OutlineShape.java.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ hashCode()

final int com.jogamp.graph.curve.OutlineShape.hashCode ( )

Definition at line 1179 of file OutlineShape.java.

◆ isComplex()

boolean com.jogamp.graph.curve.OutlineShape.isComplex ( )

Returns cached or computed result if at least one polyline of getOutline(int) is a complex shape, see Outline#isComplex().

A polyline with less than 3 elements is marked a simple shape for simplicity.

The result is cached.

See also
setOverrideConvex(boolean)
clearOverrideConvex()

Definition at line 288 of file OutlineShape.java.

Here is the call graph for this function:

◆ lineTo()

final void com.jogamp.graph.curve.OutlineShape.lineTo ( final float  x,
final float  y,
final float  z 
)

Add a line segment, intersecting the last point and the given point x/y (P1).

Parameters
xfinal point (P1)
yfinal point (P1)
zfinal point (P1)
See also
Path2F::lineTo(float, float)
addPath(com.jogamp.math.geom.plane.Path2F.Iterator, boolean)
see winding rules

Definition at line 770 of file OutlineShape.java.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ moveTo()

final void com.jogamp.graph.curve.OutlineShape.moveTo ( final float  x,
final float  y,
final float  z 
)

Start a new position for the next line segment at given point x/y (P1).

Parameters
xpoint (P1)
ypoint (P1)
zpoint (P1)
See also
Path2F::moveTo(float, float)
addPath(com.jogamp.math.geom.plane.Path2F.Iterator, boolean)
see winding rules

Definition at line 750 of file OutlineShape.java.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ print()

void com.jogamp.graph.curve.OutlineShape.print ( final PrintStream  out)

Definition at line 1189 of file OutlineShape.java.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ printPerf()

static void com.jogamp.graph.curve.OutlineShape.printPerf ( final PrintStream  out)
static

Definition at line 1030 of file OutlineShape.java.

◆ quadTo()

final void com.jogamp.graph.curve.OutlineShape.quadTo ( final float  x1,
final float  y1,
final float  z1,
final float  x2,
final float  y2,
final float  z2 
)

Add a quadratic curve segment, intersecting the last point and the second given point x2/y2 (P2).

Parameters
x1quadratic parametric control point (P1)
y1quadratic parametric control point (P1)
z1quadratic parametric control point (P1)
x2final interpolated control point (P2)
y2final interpolated control point (P2)
z2quadratic parametric control point (P2)
See also
Path2F::quadTo(float, float, float, float)
addPath(com.jogamp.math.geom.plane.Path2F.Iterator, boolean)
see winding rules

Definition at line 787 of file OutlineShape.java.

Here is the call graph for this function:

◆ removeOutline()

final Outline com.jogamp.graph.curve.OutlineShape.removeOutline ( final int  position) throws IndexOutOfBoundsException

Removes the Outline element at the given position.

Sets the bounding box dirty, hence a next call to getBounds() will validate it.

Parameters
positionof the to be removed Outline
Exceptions
IndexOutOfBoundsExceptionif position is out of range (position < 0 || position >= getOutlineNumber())

Definition at line 431 of file OutlineShape.java.

◆ setIsQuadraticNurbs()

final void com.jogamp.graph.curve.OutlineShape.setIsQuadraticNurbs ( )

Claim this outline's vertices are all OutlineShape.VerticesState#QUADRATIC_NURBS, hence no cubic transformations will be performed.

Definition at line 837 of file OutlineShape.java.

Here is the caller graph for this function:

◆ setOutline()

final void com.jogamp.graph.curve.OutlineShape.setOutline ( final int  position,
final Outline  outline 
) throws NullPointerException, IndexOutOfBoundsException

Replaces the Outline element at the given position.

Sets the bounding box dirty, hence a next call to getBounds() will validate it.

Parameters
positionof the replaced Outline
outlinereplacement Outline object
Exceptions
NullPointerExceptionif the Outline element is null
IndexOutOfBoundsExceptionif position is out of range (position < 0 || position >= getOutlineNumber())

Definition at line 416 of file OutlineShape.java.

◆ setOverrideConvex()

void com.jogamp.graph.curve.OutlineShape.setOverrideConvex ( final boolean  convex)

Overrides isComplex() using the given value instead of computing via Outline#isComplex().

See also
clearOverrideConvex()
isComplex()

Definition at line 307 of file OutlineShape.java.

◆ setSharpness()

final void com.jogamp.graph.curve.OutlineShape.setSharpness ( final float  s)

Sets sharpness, defaults to DEFAULT_SHARPNESS.

Definition at line 217 of file OutlineShape.java.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ setWindingOfLastOutline()

final void com.jogamp.graph.curve.OutlineShape.setWindingOfLastOutline ( final Winding  enforced)

Sets the enforced Winding of the getLastOutline().

Definition at line 273 of file OutlineShape.java.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ toString()

String com.jogamp.graph.curve.OutlineShape.toString ( )

Definition at line 1184 of file OutlineShape.java.

◆ transform()

final OutlineShape com.jogamp.graph.curve.OutlineShape.transform ( final AffineTransform  t)

Return a transformed instance with all Outlines are copied and transformed.

Note: Triangulated data is lost in returned instance!

Definition at line 1091 of file OutlineShape.java.

Here is the call graph for this function:

Member Data Documentation

◆ DEFAULT_SHARPNESS

final float com.jogamp.graph.curve.OutlineShape.DEFAULT_SHARPNESS = 0.5f
static

Initial getSharpness() value, which can be modified via setSharpness(float).

Definition at line 141 of file OutlineShape.java.


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