summaryrefslogtreecommitdiffstats
path: root/src/jogl/classes/jogamp/graph/curve/text
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2012-02-25 13:57:48 +0100
committerSven Gothel <[email protected]>2012-02-25 13:57:48 +0100
commit1c8f158c57a13274e3776d3ecb24cbd1c9765741 (patch)
treef9688983c920aef64827fb5b0346329b1d8f3cf6 /src/jogl/classes/jogamp/graph/curve/text
parent49114a63102c745b3db204315ad9525d61767d57 (diff)
Min. Graph Parameter type change: texSize/width/.. for multipass-renderer: int -> int[]
"texWidth desired texture width for multipass-rendering. The actual used texture-width is written back when mp rendering is enabled, otherwise the store is untouched." This allows the 'backend' to correct the texSize, ie in regards to GL_MAX_TEXTURE_SIZE .. etc. Without this write-back, it would re-create the FBO for every frame.
Diffstat (limited to 'src/jogl/classes/jogamp/graph/curve/text')
-rw-r--r--src/jogl/classes/jogamp/graph/curve/text/GlyphString.java13
1 files changed, 10 insertions, 3 deletions
diff --git a/src/jogl/classes/jogamp/graph/curve/text/GlyphString.java b/src/jogl/classes/jogamp/graph/curve/text/GlyphString.java
index bc9a93042..f86d02f40 100644
--- a/src/jogl/classes/jogamp/graph/curve/text/GlyphString.java
+++ b/src/jogl/classes/jogamp/graph/curve/text/GlyphString.java
@@ -45,6 +45,7 @@ import com.jogamp.graph.curve.OutlineShape;
import com.jogamp.graph.curve.Region;
import com.jogamp.graph.curve.opengl.GLRegion;
import com.jogamp.graph.curve.opengl.RenderState;
+import com.jogamp.opengl.util.PMVMatrix;
public class GlyphString {
/** Static font size for all default font OutlineShape generations via {@link #createString(OutlineShape, Factory, Font, String)}.
@@ -171,13 +172,19 @@ public class GlyphString {
* previously generated.
*/
public void renderString3D(GL2ES2 gl) {
- region.draw(gl, null, 0, 0, 0);
+ region.draw(gl, null, 0, 0, null);
}
/** Render the Object based using the associated Region
* previously generated.
+ * @param matrix current {@link PMVMatrix}.
+ * @param rs the RenderState to be used
+ * @param vp_width current screen width
+ * @param vp_height current screen height
+ * @param texWidth desired texture width for multipass-rendering.
+ * The actual used texture-width is written back when mp rendering is enabled, otherwise the store is untouched.
*/
- public void renderString3D(GL2ES2 gl, RenderState rs, int vp_width, int vp_height, int size) {
- region.draw(gl, rs, vp_width, vp_height, size);
+ public void renderString3D(GL2ES2 gl, RenderState rs, int vp_width, int vp_height, int[/*1*/] texWidth) {
+ region.draw(gl, rs, vp_width, vp_height, texWidth);
}
/** Get the Origin of this GlyphString