Redone font converter wip

This commit is contained in:
Willem Cazander 2022-02-21 00:41:24 +01:00
parent 9008ea2f22
commit 9f727d318f
18 changed files with 376 additions and 376 deletions

View file

@ -43,8 +43,8 @@ import love.distributedrebirth.numberxd.base2t.Base2PartsFactory;
import love.distributedrebirth.numberxd.base2t.Base2Terminator;
import love.distributedrebirth.numberxd.base2t.part.warp.TOSWarpCore;
import love.distributedrebirth.numberxd.glyph.BaseGlyphSet;
import love.distributedrebirth.unicode4d.base.UnicodePlane;
import love.distributedrebirth.unicode4d.base.UnicodePlaneDriver;
import love.distributedrebirth.unicode4d.atlas.FontAtlas;
import love.distributedrebirth.unicode4d.atlas.FontAtlasDriver;
import love.distributedrebirth.warpme.TOSWarpCoreDriver;
import love.distributedrebirth.warpme.core.WaterBucket;
import net.spookygames.gdx.nativefilechooser.NativeFileChooser;
@ -66,7 +66,7 @@ public enum GDXAppMain implements DefaultEnumInstanceᴶᴹˣ<GDXAppMain,GDXAppM
public int viewWidth;
public int viewHeight;
public MusicManager music;
public UnicodePlane basePlane;
public FontAtlas basePlane;
public ImBoolean showImGuiDemo = new ImBoolean(false);
private Map<Class<? extends Screen>,Screen> screens;
private DeskTopScreenMenu screenMenu;
@ -114,7 +114,7 @@ public enum GDXAppMain implements DefaultEnumInstanceᴶᴹˣ<GDXAppMain,GDXAppM
System.out.println("BãßBȍőnCoffinʸᴰ init done.");
try {
basePlane = UnicodePlaneDriver.newInstance().createReader().readString(Gdx.files.internal("font/unicode4d.xml").readString());
basePlane = FontAtlasDriver.newInstance().createReader().readString(Gdx.files.internal("font/unicode4d.xml").readString());
if (args.contains("warpcore-load")) {

View file

@ -1,5 +1,7 @@
package love.distributedrebirth.gdxapp.desktop.apps;
import java.util.List;
import imgui.ImColor;
import imgui.ImDrawList;
import imgui.ImGui;
@ -9,8 +11,9 @@ import love.distributedrebirth.gdxapp.GDXAppMain;
import love.distributedrebirth.gdxapp.desktop.DefaultDeskApp;
import love.distributedrebirth.gdxapp.desktop.DeskAppContourSection;
import love.distributedrebirth.gdxapp.desktop.DeskAppRenderer;
import love.distributedrebirth.unicode4d.base.UnicodePlaneBase;
import love.distributedrebirth.unicode4d.base.UnicodePlaneBaseGlyph;
import love.distributedrebirth.numberxd.base2t.type.V072Tong;
import love.distributedrebirth.unicode4d.atlas.FontAtlasStore;
import love.distributedrebirth.unicode4d.atlas.FontAtlasStoreGlyph;
@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天")
public class Unicode4DApp extends DefaultDeskApp implements DeskAppRenderer {
@ -24,8 +27,8 @@ public class Unicode4DApp extends DefaultDeskApp implements DeskAppRenderer {
public void render() {
ImGui.text("There is unicode and unicode4D");
UnicodePlaneBase plane = GDXAppMain.INSTANCE.basePlane.getPlaneByName("MISCELLANEOUS_MATHEMATICAL_SYMBOLS_A");
UnicodePlaneBaseGlyph glyph = plane.getBaseGlyphByUnicode("27d6");
//FontAtlasStore plane = GDXAppMain.INSTANCE.basePlane.getPlaneByName("MISCELLANEOUS_MATHEMATICAL_SYMBOLS_A");
FontAtlasStoreGlyph glyph = null; //plane.getBaseGlyphByUnicode("27d6");
ImCharacter c = new ImCharacter(glyph);
@ -34,10 +37,12 @@ public class Unicode4DApp extends DefaultDeskApp implements DeskAppRenderer {
class ImCharacter {
private final UnicodePlaneBaseGlyph glyph;
private final FontAtlasStoreGlyph glyph;
public ImCharacter(UnicodePlaneBaseGlyph glyph) {
public ImCharacter(FontAtlasStoreGlyph glyph) {
this.glyph = glyph;
List<V072Tong> tongs = glyph.getTongs();
}
public void render() {