Class BedrockTrueTypeFont
java.lang.Object
com.viaversion.viafabricplus.bedrock.render.font.BedrockTrueTypeFont
- All Implemented Interfaces:
com.mojang.blaze3d.font.GlyphProvider, AutoCloseable
public final class BedrockTrueTypeFont
extends Object
implements com.mojang.blaze3d.font.GlyphProvider
Owns native CPU font resources; Java's stitcher owns the uploaded glyph textures.
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.mojang.blaze3d.font.GlyphProvider
com.mojang.blaze3d.font.GlyphProvider.Conditional -
Field Summary
Fields inherited from interface com.mojang.blaze3d.font.GlyphProvider
BASELINE -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()com.mojang.blaze3d.font.UnbakedGlyphgetGlyph(int codepoint) it.unimi.dsi.fastutil.ints.IntSetstatic com.mojang.blaze3d.font.GlyphProviderload(net.minecraft.server.packs.resources.ResourceManager resources, net.minecraft.resources.Identifier location, String skip) The descriptor and bytes must come from the same selected pack.static booleanowns(net.minecraft.resources.Identifier location) static booleanusesNativeSampling(com.mojang.blaze3d.font.GlyphBitmap bitmap) static booleanusesNativeSampling(net.minecraft.client.gui.font.TextRenderable renderable)
-
Method Details
-
owns
public static boolean owns(net.minecraft.resources.Identifier location) -
load
public static com.mojang.blaze3d.font.GlyphProvider load(net.minecraft.server.packs.resources.ResourceManager resources, net.minecraft.resources.Identifier location, String skip) throws IOException The descriptor and bytes must come from the same selected pack. Older exports use vanilla loading.- Throws:
IOException
-
getSupportedGlyphs
public it.unimi.dsi.fastutil.ints.IntSet getSupportedGlyphs()- Specified by:
getSupportedGlyphsin interfacecom.mojang.blaze3d.font.GlyphProvider
-
getGlyph
public com.mojang.blaze3d.font.UnbakedGlyph getGlyph(int codepoint) - Specified by:
getGlyphin interfacecom.mojang.blaze3d.font.GlyphProvider
-
close
public void close()- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfacecom.mojang.blaze3d.font.GlyphProvider
-
usesNativeSampling
public static boolean usesNativeSampling(net.minecraft.client.gui.font.TextRenderable renderable) -
usesNativeSampling
public static boolean usesNativeSampling(com.mojang.blaze3d.font.GlyphBitmap bitmap)
-