Skip to content

Package com.mojang.blaze3d.font

Part 1/1


GlyphInfo

  • Full name: com.mojang.blaze3d.font.GlyphInfo
  • Package: com.mojang.blaze3d.font
  • Source: clientOnlycom/mojang/blaze3d/font/GlyphInfo.java
  • Type: interface
  • Modifiers: public

com.mojang.blaze3d.font.GlyphInfo#bake(Function<SheetGlyphInfo, BakedGlyph>)

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/GlyphInfo.java:25
  • Modifiers: ``
  • Return: BakedGlyph

คืออะไร

ดำเนินการ bake ตาม implementation ของ GlyphInfo

ทำงานยังไง

ไม่มี body ใน source declaration นี้

Parameters

  • Function<SheetGlyphInfo, BakedGlyph> function

ตัวอย่างใช้งาน

GlyphInfo instance = ...;
Function<SheetGlyphInfo, BakedGlyph> function = ...;
BakedGlyph result = instance.bake(function);

com.mojang.blaze3d.font.GlyphInfo#getAdvance()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/GlyphInfo.java:11
  • Modifiers: ``
  • Return: float

คืออะไร

อ่านค่า Advance

ทำงานยังไง

ไม่มี body ใน source declaration นี้

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

GlyphInfo instance = ...;
float result = instance.getAdvance();

com.mojang.blaze3d.font.GlyphInfo#getAdvance(boolean)

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/GlyphInfo.java:13
  • Modifiers: default
  • Return: float

คืออะไร

อ่านค่า Advance

ทำงานยังไง

เรียกต่อ: getBoldOffset(). คืนค่า: this.getAdvance() + (bl ? this.getBoldOffset() : 0.0F).

Parameters

  • boolean bl

ตัวอย่างใช้งาน

GlyphInfo instance = ...;
float result = instance.getAdvance(true);

com.mojang.blaze3d.font.GlyphInfo#getBoldOffset()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/GlyphInfo.java:17
  • Modifiers: default
  • Return: float

คืออะไร

อ่านค่า Bold Offset

ทำงานยังไง

คืนค่า: 1.0F.

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

GlyphInfo instance = ...;
float result = instance.getBoldOffset();

com.mojang.blaze3d.font.GlyphInfo#getShadowOffset()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/GlyphInfo.java:21
  • Modifiers: default
  • Return: float

คืออะไร

อ่านค่า Shadow Offset

ทำงานยังไง

คืนค่า: 1.0F.

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

GlyphInfo instance = ...;
float result = instance.getShadowOffset();

GlyphProvider

  • Full name: com.mojang.blaze3d.font.GlyphProvider
  • Package: com.mojang.blaze3d.font
  • Source: clientOnlycom/mojang/blaze3d/font/GlyphProvider.java
  • Type: interface
  • Modifiers: public
  • Implements: AutoCloseable

com.mojang.blaze3d.font.GlyphProvider#close()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/GlyphProvider.java:13
  • Modifiers: default
  • Return: void

คืออะไร

ปิด close

ทำงานยังไง

ทำงานตาม body โดยตรง (ประมาณ 1 statement).

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

GlyphProvider instance = ...;
instance.close();

com.mojang.blaze3d.font.GlyphProvider#getGlyph(int)

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/GlyphProvider.java:17
  • Modifiers: default
  • Return: GlyphInfo

คืออะไร

อ่านค่า Glyph

ทำงานยังไง

คืนค่า: null.

Parameters

  • int i

ตัวอย่างใช้งาน

GlyphProvider instance = ...;
GlyphInfo result = instance.getGlyph(0);

com.mojang.blaze3d.font.GlyphProvider#getSupportedGlyphs()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/GlyphProvider.java:22
  • Modifiers: ``
  • Return: IntSet

คืออะไร

อ่านค่า Supported Glyphs

ทำงานยังไง

ไม่มี body ใน source declaration นี้

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

GlyphProvider instance = ...;
IntSet result = instance.getSupportedGlyphs();

SheetGlyphInfo

  • Full name: com.mojang.blaze3d.font.SheetGlyphInfo
  • Package: com.mojang.blaze3d.font
  • Source: clientOnlycom/mojang/blaze3d/font/SheetGlyphInfo.java
  • Type: interface
  • Modifiers: public

com.mojang.blaze3d.font.SheetGlyphInfo#getBearingLeft()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/SheetGlyphInfo.java:34
  • Modifiers: default
  • Return: float

คืออะไร

อ่านค่า Bearing Left

ทำงานยังไง

คืนค่า: 0.0F.

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

SheetGlyphInfo instance = ...;
float result = instance.getBearingLeft();

com.mojang.blaze3d.font.SheetGlyphInfo#getBearingTop()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/SheetGlyphInfo.java:38
  • Modifiers: default
  • Return: float

คืออะไร

อ่านค่า Bearing Top

ทำงานยังไง

คืนค่า: 7.0F.

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

SheetGlyphInfo instance = ...;
float result = instance.getBearingTop();

com.mojang.blaze3d.font.SheetGlyphInfo#getBottom()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/SheetGlyphInfo.java:30
  • Modifiers: default
  • Return: float

คืออะไร

อ่านค่า Bottom

ทำงานยังไง

เรียกต่อ: getTop(), getPixelHeight(), getOversample(). คืนค่า: this.getTop() + this.getPixelHeight() / this.getOversample().

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

SheetGlyphInfo instance = ...;
float result = instance.getBottom();

com.mojang.blaze3d.font.SheetGlyphInfo#getLeft()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/SheetGlyphInfo.java:18
  • Modifiers: default
  • Return: float

คืออะไร

อ่านค่า Left

ทำงานยังไง

เรียกต่อ: getBearingLeft(). คืนค่า: this.getBearingLeft().

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

SheetGlyphInfo instance = ...;
float result = instance.getLeft();

com.mojang.blaze3d.font.SheetGlyphInfo#getOversample()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/SheetGlyphInfo.java:16
  • Modifiers: ``
  • Return: float

คืออะไร

อ่านค่า Oversample

ทำงานยังไง

ไม่มี body ใน source declaration นี้

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

SheetGlyphInfo instance = ...;
float result = instance.getOversample();

com.mojang.blaze3d.font.SheetGlyphInfo#getPixelHeight()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/SheetGlyphInfo.java:10
  • Modifiers: ``
  • Return: int

คืออะไร

อ่านค่า Pixel Height

ทำงานยังไง

ไม่มี body ใน source declaration นี้

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

SheetGlyphInfo instance = ...;
int result = instance.getPixelHeight();

com.mojang.blaze3d.font.SheetGlyphInfo#getPixelWidth()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/SheetGlyphInfo.java:8
  • Modifiers: ``
  • Return: int

คืออะไร

อ่านค่า Pixel Width

ทำงานยังไง

ไม่มี body ใน source declaration นี้

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

SheetGlyphInfo instance = ...;
int result = instance.getPixelWidth();

com.mojang.blaze3d.font.SheetGlyphInfo#getRight()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/SheetGlyphInfo.java:22
  • Modifiers: default
  • Return: float

คืออะไร

อ่านค่า Right

ทำงานยังไง

เรียกต่อ: getLeft(), getPixelWidth(), getOversample(). คืนค่า: this.getLeft() + this.getPixelWidth() / this.getOversample().

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

SheetGlyphInfo instance = ...;
float result = instance.getRight();

com.mojang.blaze3d.font.SheetGlyphInfo#getTop()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/SheetGlyphInfo.java:26
  • Modifiers: default
  • Return: float

คืออะไร

อ่านค่า Top

ทำงานยังไง

เรียกต่อ: getBearingTop(). คืนค่า: 7.0F - this.getBearingTop().

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

SheetGlyphInfo instance = ...;
float result = instance.getTop();

com.mojang.blaze3d.font.SheetGlyphInfo#isColored()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/SheetGlyphInfo.java:14
  • Modifiers: ``
  • Return: boolean

คืออะไร

ตรวจสอบสถานะ Colored

ทำงานยังไง

ไม่มี body ใน source declaration นี้

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

SheetGlyphInfo instance = ...;
boolean result = instance.isColored();

com.mojang.blaze3d.font.SheetGlyphInfo#upload(int,int)

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/SheetGlyphInfo.java:12
  • Modifiers: ``
  • Return: void

คืออะไร

ดำเนินการ upload ตาม implementation ของ SheetGlyphInfo

ทำงานยังไง

ไม่มี body ใน source declaration นี้

Parameters

  • int i
  • int j

ตัวอย่างใช้งาน

SheetGlyphInfo instance = ...;
instance.upload(0, 0);

SpaceProvider

  • Full name: com.mojang.blaze3d.font.SpaceProvider
  • Package: com.mojang.blaze3d.font
  • Source: clientOnlycom/mojang/blaze3d/font/SpaceProvider.java
  • Type: class
  • Modifiers: public
  • Implements: GlyphProvider

com.mojang.blaze3d.font.SpaceProvider#getGlyph(int)

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/SpaceProvider.java:28
  • Modifiers: public
  • Return: GlyphInfo

คืออะไร

อ่านค่า Glyph

ทำงานยังไง

เรียกต่อ: get(). คืนค่า: this.glyphs.get(i).

Parameters

  • int i

ตัวอย่างใช้งาน

SpaceProvider instance = ...;
GlyphInfo result = instance.getGlyph(0);

com.mojang.blaze3d.font.SpaceProvider#getSupportedGlyphs()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/SpaceProvider.java:34
  • Modifiers: public
  • Return: IntSet

คืออะไร

อ่านค่า Supported Glyphs

ทำงานยังไง

เรียกต่อ: unmodifiable(), keySet(). คืนค่า: IntSets.unmodifiable(this.glyphs.keySet()).

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

SpaceProvider instance = ...;
IntSet result = instance.getSupportedGlyphs();

com.mojang.blaze3d.font.SpaceProvider#SpaceProvider(Map<Integer, Float>)

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/SpaceProvider.java:23
  • Modifiers: public
  • Kind: constructor

คืออะไร

สร้างออบเจ็กต์ SpaceProvider ด้วยพารามิเตอร์ที่ระบุ

ทำงานยังไง

แก้ state: glyphs. เรียกต่อ: size(), forEach(), put(), intValue(). สร้างออบเจ็กต์: Int2ObjectOpenHashMap<>.

Parameters

  • Map<Integer, Float> map

ตัวอย่างใช้งาน

Map<Integer, Float> map = ...;
SpaceProvider instance = new SpaceProvider(map);

SpaceProvider$Definition

  • Full name: com.mojang.blaze3d.font.SpaceProvider$Definition
  • Package: com.mojang.blaze3d.font
  • Source: clientOnlycom/mojang/blaze3d/font/SpaceProvider.java
  • Type: record
  • Modifiers: public
  • Implements: GlyphProviderDefinition

com.mojang.blaze3d.font.SpaceProvider$Definition#type()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/SpaceProvider.java:46
  • Modifiers: public
  • Return: GlyphProviderType

คืออะไร

ดำเนินการ type ตาม implementation ของ SpaceProvider$Definition

ทำงานยังไง

คืนค่า: GlyphProviderType.SPACE.

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

SpaceProvider.Definition instance = ...;
GlyphProviderType result = instance.type();

com.mojang.blaze3d.font.SpaceProvider$Definition#unpack()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/SpaceProvider.java:51
  • Modifiers: public
  • Return: Either<GlyphProviderDefinition.Loader, GlyphProviderDefinition.Reference>

คืออะไร

ดำเนินการ unpack ตาม implementation ของ SpaceProvider$Definition

ทำงานยังไง

เรียกต่อ: left(). สร้างออบเจ็กต์: SpaceProvider. คืนค่า: Either.left(loader).

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

SpaceProvider.Definition instance = ...;
Either<GlyphProviderDefinition.Loader, GlyphProviderDefinition.Reference> result = instance.unpack();

TrueTypeGlyphProvider

  • Full name: com.mojang.blaze3d.font.TrueTypeGlyphProvider
  • Package: com.mojang.blaze3d.font
  • Source: clientOnlycom/mojang/blaze3d/font/TrueTypeGlyphProvider.java
  • Type: class
  • Modifiers: public
  • Implements: GlyphProvider

com.mojang.blaze3d.font.TrueTypeGlyphProvider#close()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/TrueTypeGlyphProvider.java:118
  • Modifiers: public
  • Return: void

คืออะไร

ปิด close

ทำงานยังไง

ตรวจเงื่อนไขด้วย if ; มีส่วนที่ synchronize การทำงาน. แก้ state: face, fontMemory. เรียกต่อ: checkError(), FT_Done_Face(), memFree().

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

TrueTypeGlyphProvider instance = ...;
instance.close();

com.mojang.blaze3d.font.TrueTypeGlyphProvider#getGlyph(int)

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/TrueTypeGlyphProvider.java:67
  • Modifiers: public
  • Return: GlyphInfo

คืออะไร

อ่านค่า Glyph

ทำงานยังไง

เรียกต่อ: get(), getOrLoadGlyphInfo(). คืนค่า: glyphEntry != null ? this.getOrLoadGlyphInfo(i, glyphEntry) : null.

Parameters

  • int i

ตัวอย่างใช้งาน

TrueTypeGlyphProvider instance = ...;
GlyphInfo result = instance.getGlyph(0);

com.mojang.blaze3d.font.TrueTypeGlyphProvider#getSupportedGlyphs()

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/TrueTypeGlyphProvider.java:132
  • Modifiers: public
  • Return: IntSet

คืออะไร

อ่านค่า Supported Glyphs

ทำงานยังไง

เรียกต่อ: keySet(). คืนค่า: this.glyphs.keySet().

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

TrueTypeGlyphProvider instance = ...;
IntSet result = instance.getSupportedGlyphs();

com.mojang.blaze3d.font.TrueTypeGlyphProvider#TrueTypeGlyphProvider(ByteBuffer,FT_Face,float,float,float,float,String)

  • Origin: clientOnly
  • Source: com/mojang/blaze3d/font/TrueTypeGlyphProvider.java:35
  • Modifiers: public
  • Kind: constructor

คืออะไร

สร้างออบเจ็กต์ TrueTypeGlyphProvider ด้วยพารามิเตอร์ที่ระบุ

ทำงานยังไง

ตรวจเงื่อนไขด้วย if ; มีการวนลูป ; มีการจัดการ exception. แก้ state: fontMemory, face, oversample. เรียกต่อ: codePoints(), forEach(), round(), FT_Set_Pixel_Sizes(), stackPush(), setVector(), malloc(), FT_Set_Transform(). สร้างออบเจ็กต์: IntArraySet, TrueTypeGlyphProvider.GlyphEntry.

Parameters

  • ByteBuffer byteBuffer
  • FT_Face fT_Face
  • float f
  • float g
  • float h
  • float i
  • String string

ตัวอย่างใช้งาน

ByteBuffer byteBuffer = ...;
FT_Face fT_Face = ...;
TrueTypeGlyphProvider instance = new TrueTypeGlyphProvider(byteBuffer, fT_Face, 0.0F, 0.0F, 0.0F, 0.0F, "value");