aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/jogl/classes/com/jogamp/graph/curve/opengl/Renderer.java4
-rw-r--r--src/jogl/classes/jogamp/graph/curve/opengl/TextRendererImpl01.java2
-rw-r--r--src/test/com/jogamp/opengl/test/junit/graph/demos/GPURendererListenerBase01.java2
-rw-r--r--src/test/com/jogamp/opengl/test/junit/graph/demos/GPUTextRendererListenerBase01.java12
4 files changed, 16 insertions, 4 deletions
diff --git a/src/jogl/classes/com/jogamp/graph/curve/opengl/Renderer.java b/src/jogl/classes/com/jogamp/graph/curve/opengl/Renderer.java
index 863928ed4..57eeb016f 100644
--- a/src/jogl/classes/com/jogamp/graph/curve/opengl/Renderer.java
+++ b/src/jogl/classes/com/jogamp/graph/curve/opengl/Renderer.java
@@ -104,6 +104,10 @@ public abstract class Renderer {
}
public final ShaderState getShaderState() { return st; }
+
+ public final void enable(GL2ES2 gl, boolean enable) {
+ st.glUseProgram(gl, enable);
+ }
public final PMVMatrix getMatrix() { return pmvMatrix; }
diff --git a/src/jogl/classes/jogamp/graph/curve/opengl/TextRendererImpl01.java b/src/jogl/classes/jogamp/graph/curve/opengl/TextRendererImpl01.java
index cebe7a19e..0f0b91412 100644
--- a/src/jogl/classes/jogamp/graph/curve/opengl/TextRendererImpl01.java
+++ b/src/jogl/classes/jogamp/graph/curve/opengl/TextRendererImpl01.java
@@ -139,7 +139,7 @@ public class TextRendererImpl01 extends TextRenderer {
if(DEBUG) {
System.err.println("TextRendererImpl01 initialized: " + Thread.currentThread()+" "+st);
- }
+ }
return true;
}
diff --git a/src/test/com/jogamp/opengl/test/junit/graph/demos/GPURendererListenerBase01.java b/src/test/com/jogamp/opengl/test/junit/graph/demos/GPURendererListenerBase01.java
index 30f7ec384..e63985be9 100644
--- a/src/test/com/jogamp/opengl/test/junit/graph/demos/GPURendererListenerBase01.java
+++ b/src/test/com/jogamp/opengl/test/junit/graph/demos/GPURendererListenerBase01.java
@@ -112,7 +112,7 @@ public abstract class GPURendererListenerBase01 implements GLEventListener {
public void reshape(GLAutoDrawable drawable, int xstart, int ystart, int width, int height) {
GL2ES2 gl = drawable.getGL().getGL2ES2();
- gl.glViewport(xstart, ystart, width, height);
+ gl.glViewport(xstart, ystart, width, height);
renderer.reshapePerspective(gl, 45.0f, width, height, 0.1f, 7000.0f);
dumpMatrix();
diff --git a/src/test/com/jogamp/opengl/test/junit/graph/demos/GPUTextRendererListenerBase01.java b/src/test/com/jogamp/opengl/test/junit/graph/demos/GPUTextRendererListenerBase01.java
index bdfaab17b..a3ea93dff 100644
--- a/src/test/com/jogamp/opengl/test/junit/graph/demos/GPUTextRendererListenerBase01.java
+++ b/src/test/com/jogamp/opengl/test/junit/graph/demos/GPUTextRendererListenerBase01.java
@@ -92,12 +92,18 @@ public abstract class GPUTextRendererListenerBase01 extends GPURendererListenerB
public GPUTextRendererListenerBase01(Vertex.Factory<? extends Vertex> factory, int mode, boolean debug, boolean trace) {
super(TextRenderer.create(factory, mode), debug, trace);
this.font = FontFactory.get(fontSet).getDefault();
- System.err.println(font.getAllNames(null, "\n"));
+ dumpFontNames();
this.fontName = font.getName(Font.NAME_FAMILY) + " - " + font.getName(Font.NAME_SUBFAMILY);
this.fontNameBox = font.getStringBounds(fontName, fontSizeFixed*2);
switchHeadBox();
}
+
+ void dumpFontNames() {
+ System.err.println("+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++");
+ System.err.println(font.getAllNames(null, "\n"));
+ System.err.println("+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++");
+ }
void switchHeadBox() {
headType = ( headType + 1 ) % 3 ;
@@ -181,11 +187,13 @@ public abstract class GPUTextRendererListenerBase01 extends GPURendererListenerB
font = FontFactory.get(fontSet).getDefault();
this.fontName = font.getName(Font.NAME_FAMILY) + " - " + font.getName(Font.NAME_SUBFAMILY);
this.fontNameBox = font.getStringBounds(fontName, fontSizeFixed*3);
+ dumpFontNames();
}
public void setFontSet(int set, int family, int stylebits) {
fontSet = set;
- font = FontFactory.get(fontSet).get(family, stylebits);
+ font = FontFactory.get(fontSet).get(family, stylebits);
+ dumpFontNames();
}
public boolean isUserInputMode() { return userInput; }