diff options
Diffstat (limited to 'src/jogl/classes/com/jogamp/graph/curve/opengl')
-rw-r--r-- | src/jogl/classes/com/jogamp/graph/curve/opengl/Renderer.java | 7 | ||||
-rw-r--r-- | src/jogl/classes/com/jogamp/graph/curve/opengl/TextRenderer.java | 3 |
2 files changed, 8 insertions, 2 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 aa14bcbd8..ce3e83692 100644 --- a/src/jogl/classes/com/jogamp/graph/curve/opengl/Renderer.java +++ b/src/jogl/classes/com/jogamp/graph/curve/opengl/Renderer.java @@ -125,6 +125,13 @@ public abstract class Renderer { st.glUniform(gl, mgl_PMVMatrix); } } + + public void scale(GL2ES2 gl, float x, float y, float z) { + pmvMatrix.glScalef(x, y, z); + if(initialized && null != gl && st.inUse()) { + st.glUniform(gl, mgl_PMVMatrix); + } + } public void resetModelview(GL2ES2 gl) { pmvMatrix.glMatrixMode(GLMatrixFunc.GL_MODELVIEW); diff --git a/src/jogl/classes/com/jogamp/graph/curve/opengl/TextRenderer.java b/src/jogl/classes/com/jogamp/graph/curve/opengl/TextRenderer.java index 4b7299a33..ee8dfb372 100644 --- a/src/jogl/classes/com/jogamp/graph/curve/opengl/TextRenderer.java +++ b/src/jogl/classes/com/jogamp/graph/curve/opengl/TextRenderer.java @@ -48,11 +48,10 @@ public abstract class TextRenderer extends Renderer { * @param sharpness parameter for Region generation of the resulting GlyphString * @return the resulting GlyphString inclusive the generated region */ - protected GlyphString createString(GL2ES2 gl, Font font, int size, String str, float sharpness) { + public GlyphString createString(GL2ES2 gl, Font font, int size, String str, float sharpness) { if(DEBUG) { System.err.println("createString: "+getCacheSize()+"/"+getCacheLimit()+" - "+Font.NAME_UNIQUNAME + " - " + str + " - " + size); } - AffineTransform affineTransform = new AffineTransform(pointFactory); Path2D[] paths = new Path2D[str.length()]; |