diff options
Diffstat (limited to 'src/jogl/classes/com/jogamp/opengl')
4 files changed, 5 insertions, 6 deletions
diff --git a/src/jogl/classes/com/jogamp/opengl/util/ImmModeSink.java b/src/jogl/classes/com/jogamp/opengl/util/ImmModeSink.java index 44026fdac..3b817afcf 100644 --- a/src/jogl/classes/com/jogamp/opengl/util/ImmModeSink.java +++ b/src/jogl/classes/com/jogamp/opengl/util/ImmModeSink.java @@ -70,7 +70,7 @@ public class ImmModeSink { } public String toString() { - StringBuffer sb = new StringBuffer("ImmModeSink["); + StringBuilder sb = new StringBuilder("ImmModeSink["); sb.append(",\n\tVBO list: "+vboSetList.size()+" ["); for(Iterator<VBOSet> i=vboSetList.iterator(); i.hasNext() ; ) { sb.append("\n\t"); diff --git a/src/jogl/classes/com/jogamp/opengl/util/awt/TextRenderer.java b/src/jogl/classes/com/jogamp/opengl/util/awt/TextRenderer.java index 4318e1244..622ee1b79 100644 --- a/src/jogl/classes/com/jogamp/opengl/util/awt/TextRenderer.java +++ b/src/jogl/classes/com/jogamp/opengl/util/awt/TextRenderer.java @@ -1603,7 +1603,7 @@ public class TextRenderer { } else { // Assemble a run of characters that don't fit in // the cache - StringBuffer buf = new StringBuffer(); + StringBuilder buf = new StringBuilder(); while (i < lengthInGlyphs && getGlyph(inString, fullRunGlyphVector.getGlyphMetrics(i), i) == null) { buf.append(inString.charAt(i++)); diff --git a/src/jogl/classes/com/jogamp/opengl/util/glsl/sdk/CompileShader.java b/src/jogl/classes/com/jogamp/opengl/util/glsl/sdk/CompileShader.java index cf3e764d0..a5b1c6687 100644 --- a/src/jogl/classes/com/jogamp/opengl/util/glsl/sdk/CompileShader.java +++ b/src/jogl/classes/com/jogamp/opengl/util/glsl/sdk/CompileShader.java @@ -3,7 +3,6 @@ package com.jogamp.opengl.util.glsl.sdk; import com.jogamp.common.util.IOUtil; import javax.media.opengl.*; -import com.jogamp.opengl.util.*; import com.jogamp.opengl.util.glsl.*; import java.io.*; @@ -68,7 +67,7 @@ public abstract class CompileShader { URL resourceURL = IOUtil.getResource(null, resourceName).getURL(); String dirName = dirname(resourceURL.getPath()); - String shader = ShaderCode.readShaderSource(null, resourceName); + CharSequence shader = ShaderCode.readShaderSource(null, resourceName, false); if(null==shader) { System.err.println("Can't find shader source " + resourceName + " - ignored"); return; @@ -93,7 +92,7 @@ public abstract class CompileShader { tmpDir.mkdirs(); File tmpFile = new File(tmpDir, justName); Writer writer = new BufferedWriter(new FileWriter(tmpFile)); - writer.write(shader, 0, shader.length()); + writer.write(shader.toString(), 0, shader.length()); writer.flush(); writer.close(); System.err.println("Preprocessed: "+ tmpFile.getAbsolutePath()); diff --git a/src/jogl/classes/com/jogamp/opengl/util/texture/spi/DDSImage.java b/src/jogl/classes/com/jogamp/opengl/util/texture/spi/DDSImage.java index 306e7d2fe..3f91ae966 100644 --- a/src/jogl/classes/com/jogamp/opengl/util/texture/spi/DDSImage.java +++ b/src/jogl/classes/com/jogamp/opengl/util/texture/spi/DDSImage.java @@ -472,7 +472,7 @@ public class DDSImage { @return String format code */ public static String getCompressionFormatName(int compressionFormat) { - StringBuffer buf = new StringBuffer(); + StringBuilder buf = new StringBuilder(); for (int i = 0; i < 4; i++) { char c = (char) (compressionFormat & 0xFF); buf.append(c); |