diff --git a/SPD-classes/src/main/java/com/watabou/noosa/BitmapText.java b/SPD-classes/src/main/java/com/watabou/noosa/BitmapText.java index ec7ca3dba..09ef45768 100644 --- a/SPD-classes/src/main/java/com/watabou/noosa/BitmapText.java +++ b/SPD-classes/src/main/java/com/watabou/noosa/BitmapText.java @@ -23,7 +23,6 @@ package com.watabou.noosa; import com.badlogic.gdx.graphics.Pixmap; import com.watabou.gltextures.SmartTexture; -import com.watabou.gltextures.TextureCache; import com.watabou.glwrap.Matrix; import com.watabou.glwrap.Quad; import com.watabou.glwrap.Vertexbuffer; @@ -342,15 +341,15 @@ public class BitmapText extends Visual { return pixel != color; } - public static Font colorMarked( Pixmap bmp, int color, String chars ) { - Font font = new Font( TextureCache.get( bmp ) ); - font.splitBy( bmp, bmp.getHeight(), color, chars ); + public static Font colorMarked( SmartTexture tex, int color, String chars ) { + Font font = new Font( tex ); + font.splitBy( tex.bitmap, tex.height, color, chars ); return font; } - public static Font colorMarked( Pixmap bmp, int height, int color, String chars ) { - Font font = new Font( TextureCache.get( bmp ) ); - font.splitBy( bmp, height, color, chars ); + public static Font colorMarked( SmartTexture tex, int height, int color, String chars ) { + Font font = new Font( tex ); + font.splitBy( tex.bitmap, height, color, chars ); return font; } diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/scenes/PixelScene.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/scenes/PixelScene.java index 74dce2b1d..597f3d6c7 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/scenes/PixelScene.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/scenes/PixelScene.java @@ -29,6 +29,7 @@ import com.shatteredpixel.shatteredpixeldungeon.messages.Languages; import com.shatteredpixel.shatteredpixeldungeon.messages.Messages; import com.shatteredpixel.shatteredpixeldungeon.ui.RenderedTextBlock; import com.shatteredpixel.shatteredpixeldungeon.ui.Window; +import com.watabou.gltextures.TextureCache; import com.watabou.glwrap.Blending; import com.watabou.input.PointerEvent; import com.watabou.noosa.BitmapText; @@ -40,7 +41,6 @@ import com.watabou.noosa.Gizmo; import com.watabou.noosa.Scene; import com.watabou.noosa.Visual; import com.watabou.noosa.ui.Component; -import com.watabou.utils.BitmapCache; import com.watabou.utils.Reflection; import java.util.ArrayList; @@ -109,7 +109,7 @@ public class PixelScene extends Scene { // 3x5 (6) pixelFont = Font.colorMarked( - BitmapCache.get( Assets.Fonts.PIXELFONT), 0x00000000, BitmapText.Font.LATIN_FULL ); + TextureCache.get( Assets.Fonts.PIXELFONT), 0x00000000, BitmapText.Font.LATIN_FULL ); pixelFont.baseLine = 6; pixelFont.tracking = -1;