summaryrefslogtreecommitdiffstats
path: root/src/jogl/classes/com/jogamp
diff options
context:
space:
mode:
Diffstat (limited to 'src/jogl/classes/com/jogamp')
-rw-r--r--src/jogl/classes/com/jogamp/graph/curve/Region.java2
-rw-r--r--src/jogl/classes/com/jogamp/graph/curve/opengl/GLRegion.java13
2 files changed, 9 insertions, 6 deletions
diff --git a/src/jogl/classes/com/jogamp/graph/curve/Region.java b/src/jogl/classes/com/jogamp/graph/curve/Region.java
index 5201d07b1..ef2bbf494 100644
--- a/src/jogl/classes/com/jogamp/graph/curve/Region.java
+++ b/src/jogl/classes/com/jogamp/graph/curve/Region.java
@@ -497,7 +497,7 @@ public abstract class Region {
final int verticeCount = vertsIn.size() + shape.getAddedVerticeCount();
final int indexCount = trisIn.size() * 3;
vertIndexCount[0] += verticeCount;
- vertIndexCount[1] += Math.min( Math.ceil(verticeCount * 0.6), indexCount );
+ vertIndexCount[1] += Math.min( Math.ceil(verticeCount * 0.9), indexCount );
}
}
diff --git a/src/jogl/classes/com/jogamp/graph/curve/opengl/GLRegion.java b/src/jogl/classes/com/jogamp/graph/curve/opengl/GLRegion.java
index 6b8aeb04b..b0f87c023 100644
--- a/src/jogl/classes/com/jogamp/graph/curve/opengl/GLRegion.java
+++ b/src/jogl/classes/com/jogamp/graph/curve/opengl/GLRegion.java
@@ -74,18 +74,21 @@ public abstract class GLRegion extends Region {
* - Ubuntu Light ~ vertices 100/char, indices 50/char
* - FreeSerif ~ vertices 115/char, indices 61/char
*
- * Now let's assume a minimum of 10 chars will be rendered
+ * However, proper initial size is pre-calculated via ..
+ * - {@link GLRegion#create(GLProfile, int, TextureSequence, Font, CharSequence)}
+ * - {@Link Region#countOutlineShape(OutlineShape, int[])}
+ * - {@link TextRegionUtil#countStringRegion(Font, CharSequence, int[])}
*/
/**
- * Default initial vertices count based on 10 chars w/ FreeSans @ 64 vertices/char avg.
+ * Default initial vertices count {@value}, assuming small sized shapes.
*/
- public static final int defaultVerticesCount = 10*64;
+ public static final int defaultVerticesCount = 16;
/**
- * Default initial indices count based on 10 chars w/ FreeSans @ 33 indices/char avg.
+ * Default initial indices count {@value}, assuming small sized shapes.
*/
- public static final int defaultIndicesCount = 10*33;
+ public static final int defaultIndicesCount = 16;
// private static final float growthFactor = 1.2f; // avg +5% size but 15% more overhead (34% total)
protected static final float growthFactor = GLArrayDataClient.DEFAULT_GROWTH_FACTOR; // avg +20% size, but 15% less CPU overhead compared to 1.2 (19% total)