Package icyllis.arc3d.granite
Class GlyphVector
java.lang.Object
icyllis.arc3d.granite.DrawAtlas.PlotBulkUseUpdater
icyllis.arc3d.granite.GlyphVector
GlyphVector provides a way to delay the lookup of GPU
Glyphs
until the code is running on the GPU in single threaded mode. The GlyphVector is created
in a multi-threaded environment, but the GlyphStrike
is only single threaded
(and must be single threaded because of the atlas).-
Constructor Summary
ConstructorsConstructorDescriptionGlyphVector
(@NonNull StrikeDesc strikeDesc, int @NonNull [] glyphs, int start, int end) All params are read-only, copy will be made. -
Method Summary
Modifier and TypeMethodDescriptionint
long
int
prepareGlyphs
(int start, int end, int maskFormat, RecordingContext context) Update atlas for glyphs in the given range if needed, returns the number of glyphs that are updated (may less than end-start if atlas is full).Methods inherited from class icyllis.arc3d.granite.DrawAtlas.PlotBulkUseUpdater
add, clear, count, dataAt
-
Constructor Details
-
GlyphVector
@Contract(pure=true) public GlyphVector(@NonNull StrikeDesc strikeDesc, int @NonNull [] glyphs, int start, int end) All params are read-only, copy will be made.
-
-
Method Details
-
getGlyphs
-
getGlyphCount
public int getGlyphCount() -
prepareGlyphs
Update atlas for glyphs in the given range if needed, returns the number of glyphs that are updated (may less than end-start if atlas is full). If an error occurred, returns the bitwise NOT (a negative value). -
getMemorySize
public long getMemorySize()- Overrides:
getMemorySize
in classDrawAtlas.PlotBulkUseUpdater
-