|
JOGL v2.6.0-rc-20250706
JOGL, High-Performance Graphics Binding for Java (public API).
|
Define a single continuous stroke by control vertices. More...
Public Member Functions | |
| Outline () | |
| Create an outline defined by control vertices. More... | |
| Outline (final Outline src) | |
| Copy ctor. More... | |
| Outline (final Outline src, final Winding enforce) | |
| Copy ctor w/ enforced Winding. More... | |
| final void | setWinding (final Winding enforce) |
Sets Winding to this outline. More... | |
| final Winding | getWinding () |
Returns the cached or computed winding of this Outlines polyline using VectorUtil#area(ArrayList). More... | |
| boolean | isComplex () |
Returns cached or computed result if whether this Outlines polyline is a complex shape. More... | |
| final int | getVertexCount () |
| final void | addVertex (final Vertex vertex) throws NullPointerException |
| Appends a vertex to the outline loop/strip. More... | |
| final void | addVertex (final int position, final Vertex vertex) throws NullPointerException, IndexOutOfBoundsException |
Insert the Vertex element at the given position to the outline loop/strip. More... | |
| final void | setVertex (final int position, final Vertex vertex) throws NullPointerException, IndexOutOfBoundsException |
Replaces the Vertex element at the given position. More... | |
| final Vertex | getVertex (final int index) |
| int | getVertexIndex (final Vertex vertex) |
| final Vertex | removeVertex (final int position) throws IndexOutOfBoundsException |
Removes the Vertex element at the given position. More... | |
| final boolean | isEmpty () |
| final Vertex | getLastVertex () |
| final ArrayList< Vertex > | getVertices () |
| final void | setVertices (final ArrayList< Vertex > vertices) |
| Use the given outline loop/strip. More... | |
| final boolean | isClosed () |
| final boolean | setClosed (final boolean closeTail) |
| Ensure this outline is closed. More... | |
| final Outline | transform (final AffineTransform t) |
| Return a transformed instance with all vertices are copied and transformed. More... | |
| final AABBox | getBounds () |
| final int | compareTo (final Outline other) |
| Compare two outline's Bounding Box size. More... | |
| boolean | equals (final Object obj) |
| final int | hashCode () |
| String | toString () |
| void | print (final PrintStream out) |
Define a single continuous stroke by control vertices.
The vertices define the shape of the region defined by this outline. The Outline can contain a list of off-curve and on-curve vertices which define curved regions.
Note: An outline should be closed to be rendered as a region.
Definition at line 53 of file Outline.java.
| com.jogamp.graph.geom.Outline.Outline | ( | ) |
Create an outline defined by control vertices.
An outline can contain off Curve vertices which define curved regions in the outline.
Definition at line 70 of file Outline.java.
| com.jogamp.graph.geom.Outline.Outline | ( | final Outline | src | ) |
Copy ctor.
Definition at line 83 of file Outline.java.
Copy ctor w/ enforced Winding.
If the enforced Winding doesn't match the source Outline, the vertices reversed copied into this new instance.
Definition at line 113 of file Outline.java.
| final void com.jogamp.graph.geom.Outline.addVertex | ( | final int | position, |
| final Vertex | vertex | ||
| ) | throws NullPointerException, IndexOutOfBoundsException |
Insert the Vertex element at the given position to the outline loop/strip.
| NullPointerException | if the Vertex element is null |
| IndexOutOfBoundsException | if position is out of range (position < 0 || position > getVertexNumber()) |
Definition at line 220 of file Outline.java.
| final void com.jogamp.graph.geom.Outline.addVertex | ( | final Vertex | vertex | ) | throws NullPointerException |
Appends a vertex to the outline loop/strip.
| vertex | Vertex to be added |
| NullPointerException | if the Vertex element is null |
Definition at line 209 of file Outline.java.
| final int com.jogamp.graph.geom.Outline.compareTo | ( | final Outline | other | ) |
Compare two outline's Bounding Box size.
Definition at line 361 of file Outline.java.
| boolean com.jogamp.graph.geom.Outline.equals | ( | final Object | obj | ) |
| obj | the Object to compare this Outline with |
obj is an Outline, not null, equals bounds and equal vertices in the same order Definition at line 378 of file Outline.java.
| final AABBox com.jogamp.graph.geom.Outline.getBounds | ( | ) |
| final Vertex com.jogamp.graph.geom.Outline.getLastVertex | ( | ) |
Definition at line 272 of file Outline.java.
| final Vertex com.jogamp.graph.geom.Outline.getVertex | ( | final int | index | ) |
| final int com.jogamp.graph.geom.Outline.getVertexCount | ( | ) |
| int com.jogamp.graph.geom.Outline.getVertexIndex | ( | final Vertex | vertex | ) |
Definition at line 252 of file Outline.java.
| final ArrayList< Vertex > com.jogamp.graph.geom.Outline.getVertices | ( | ) |
| final Winding com.jogamp.graph.geom.Outline.getWinding | ( | ) |
Returns the cached or computed winding of this Outlines polyline using VectorUtil#area(ArrayList).
The result is cached.
Winding#CCW or Winding#CW Definition at line 167 of file Outline.java.
| final int com.jogamp.graph.geom.Outline.hashCode | ( | ) |
Definition at line 400 of file Outline.java.
| final boolean com.jogamp.graph.geom.Outline.isClosed | ( | ) |
Definition at line 294 of file Outline.java.
| boolean com.jogamp.graph.geom.Outline.isComplex | ( | ) |
Returns cached or computed result if whether this Outlines polyline is a complex shape.
A polyline with less than 3 elements is marked a simple shape for simplicity.
The result is cached.
Definition at line 190 of file Outline.java.
| final boolean com.jogamp.graph.geom.Outline.isEmpty | ( | ) |
| void com.jogamp.graph.geom.Outline.print | ( | final PrintStream | out | ) |
| final Vertex com.jogamp.graph.geom.Outline.removeVertex | ( | final int | position | ) | throws IndexOutOfBoundsException |
Removes the Vertex element at the given position.
Sets the bounding box dirty, hence a next call to getBounds() will validate it.
| position | of the to be removed Vertex |
| IndexOutOfBoundsException | if position is out of range (position < 0 || position >= getVertexNumber()) |
Definition at line 262 of file Outline.java.
| final boolean com.jogamp.graph.geom.Outline.setClosed | ( | final boolean | closeTail | ) |
Ensure this outline is closed.
Checks whether the last vertex equals to the first. If not equal, it either appends a copy of the first vertex or prepends a copy of the last vertex, depending on closeTail.
| closeTail | if true, a copy of the first vertex will be appended, otherwise a copy of the last vertex will be prepended. |
Definition at line 309 of file Outline.java.
| final void com.jogamp.graph.geom.Outline.setVertex | ( | final int | position, |
| final Vertex | vertex | ||
| ) | throws NullPointerException, IndexOutOfBoundsException |
Replaces the Vertex element at the given position.
Sets the bounding box dirty, hence a next call to getBounds() will validate it.
| NullPointerException | if the Outline element is null |
| IndexOutOfBoundsException | if position is out of range (position < 0 || position >= getVertexNumber()) |
Definition at line 239 of file Outline.java.
| final void com.jogamp.graph.geom.Outline.setVertices | ( | final ArrayList< Vertex > | vertices | ) |
Use the given outline loop/strip.
Validates the bounding box.
| vertices | the new outline loop/strip |
Definition at line 289 of file Outline.java.
| final void com.jogamp.graph.geom.Outline.setWinding | ( | final Winding | enforce | ) |
| String com.jogamp.graph.geom.Outline.toString | ( | ) |
Definition at line 404 of file Outline.java.
| final Outline com.jogamp.graph.geom.Outline.transform | ( | final AffineTransform | t | ) |
Return a transformed instance with all vertices are copied and transformed.
Definition at line 329 of file Outline.java.