Package org.freedesktop.harfbuzz
Interface PaintImageFunc
- All Superinterfaces:
FunctionPointer
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface
@Generated("io.github.jwharm.JavaGI")
public interface PaintImageFunc
extends FunctionPointer
Functional interface declaration of the
PaintImageFunc
callback.
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionrun
(PaintFuncs funcs, @Nullable MemorySegment paintData, Blob image, int width, int height, Tag format, float slant, @Nullable GlyphExtents extents) A virtual method for thehb_paint_funcs_t
to paint a glyph image.default MemorySegment
toCallback
(Arena arena) Creates a native function pointer to theupcall(java.lang.foreign.MemorySegment, java.lang.foreign.MemorySegment, java.lang.foreign.MemorySegment, int, int, int, float, java.lang.foreign.MemorySegment, java.lang.foreign.MemorySegment)
method.default int
upcall
(MemorySegment funcs, MemorySegment paintData, MemorySegment image, int width, int height, int format, float slant, MemorySegment extents, MemorySegment userData) Theupcall
method is called from native code.
-
Method Details
-
run
Bool run(PaintFuncs funcs, @Nullable @Nullable MemorySegment paintData, Blob image, int width, int height, Tag format, float slant, @Nullable @Nullable GlyphExtents extents) A virtual method for thehb_paint_funcs_t
to paint a glyph image.This method is called for glyphs with image blobs in the CBDT, sbix or SVG tables. The
format
identifies the kind of data that is contained inimage
. Possible values includeHB_PAINT_IMAGE_FORMAT_PNG
,HB_PAINT_IMAGE_FORMAT_SVG
andHB_PAINT_IMAGE_FORMAT_BGRA
.The image dimensions and glyph extents are provided if available, and should be used to size and position the image.
-
upcall
default int upcall(MemorySegment funcs, MemorySegment paintData, MemorySegment image, int width, int height, int format, float slant, MemorySegment extents, MemorySegment userData) Theupcall
method is called from native code. The parameters are marshaled andrun(org.freedesktop.harfbuzz.PaintFuncs, java.lang.foreign.MemorySegment, org.freedesktop.harfbuzz.Blob, int, int, org.freedesktop.harfbuzz.Tag, float, org.freedesktop.harfbuzz.GlyphExtents)
is executed. -
toCallback
Creates a native function pointer to theupcall(java.lang.foreign.MemorySegment, java.lang.foreign.MemorySegment, java.lang.foreign.MemorySegment, int, int, int, float, java.lang.foreign.MemorySegment, java.lang.foreign.MemorySegment)
method.- Specified by:
toCallback
in interfaceFunctionPointer
- Parameters:
arena
- the function pointer will be allocated in this arena- Returns:
- the native function pointer
-