diff options
author | Sven Gothel <[email protected]> | 2011-05-08 05:36:01 +0200 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2011-05-08 05:36:01 +0200 |
commit | fc5b810cb210f22572815642cdc810c7dc472319 (patch) | |
tree | fc6f02d3652d7fe75b4018c8739728bf9fef6d7d /src/jogl/classes/jogamp/graph/curve/text/GlyphShape.java | |
parent | 624a52690b429c486bb8946d58f77936ead41785 (diff) |
Graph/GLyph*: Add static factory method for non Renderer creation,
separating text->OutlineShape and OutlineShape->Region step.
Diffstat (limited to 'src/jogl/classes/jogamp/graph/curve/text/GlyphShape.java')
-rw-r--r-- | src/jogl/classes/jogamp/graph/curve/text/GlyphShape.java | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/jogl/classes/jogamp/graph/curve/text/GlyphShape.java b/src/jogl/classes/jogamp/graph/curve/text/GlyphShape.java index 749292297..b6f37a610 100644 --- a/src/jogl/classes/jogamp/graph/curve/text/GlyphShape.java +++ b/src/jogl/classes/jogamp/graph/curve/text/GlyphShape.java @@ -72,16 +72,14 @@ public class GlyphShape { public final Vertex.Factory<? extends Vertex> vertexFactory() { return shape.vertexFactory(); } - private void addVertexToLastOutline(Vertex vertex){ + private void addVertexToLastOutline(Vertex vertex) { shape.addVertex(vertex); } private void addOutlineVerticesFromGlyphVector(float[] coords, int segmentType){ switch(segmentType) { case PathIterator.SEG_MOVETO: - if(!shape.getLastOutline().isEmpty()){ - shape.addEmptyOutline(); - } + shape.addEmptyOutline(); addVertexToLastOutline(vertexFactory().create(coords, 0, 2, true)); numVertices++; break; @@ -108,6 +106,10 @@ public class GlyphShape { } } + public OutlineShape getShape() { + return shape; + } + public int getNumVertices() { return numVertices; } |