Package org.lwjgl.stb

Class STBTTKerningentry

  • All Implemented Interfaces:
    java.lang.AutoCloseable, org.lwjgl.system.NativeResource, org.lwjgl.system.Pointer

    public class STBTTKerningentry
    extends org.lwjgl.system.Struct
    implements org.lwjgl.system.NativeResource

    Layout

    
     struct stbtt_kerningentry {
         int glyph1;
         int glyph2;
         int advance;
     }
    • Field Detail

      • SIZEOF

        The struct size in bytes.
      • ALIGNOF

        The struct alignment in bytes.
      • GLYPH1, GLYPH2, ADVANCE

        The struct member offsets.
    • Constructor Detail

      • STBTTKerningentry

        public STBTTKerningentry​(java.nio.ByteBuffer container)
        Creates a STBTTKerningentry instance at the current position of the specified ByteBuffer container. Changes to the buffer's content will be visible to the struct instance and vice versa.

        The created instance holds a strong reference to the container object.

    • Method Detail

      • sizeof

        public int sizeof()
        Specified by:
        sizeof in class org.lwjgl.system.Struct
      • glyph1

        public int glyph1()
        Returns:
        the value of the glyph1 field.
      • glyph2

        public int glyph2()
        Returns:
        the value of the glyph2 field.
      • advance

        public int advance()
        Returns:
        the value of the advance field.
      • malloc

        public static STBTTKerningentry malloc()
        Returns a new STBTTKerningentry instance allocated with memAlloc. The instance must be explicitly freed.
      • calloc

        public static STBTTKerningentry calloc()
        Returns a new STBTTKerningentry instance allocated with memCalloc. The instance must be explicitly freed.
      • create

        public static STBTTKerningentry create()
        Returns a new STBTTKerningentry instance allocated with BufferUtils.
      • create

        public static STBTTKerningentry create​(long address)
        Returns a new STBTTKerningentry instance for the specified memory address.
      • createSafe

        @Nullable
        public static STBTTKerningentry createSafe​(long address)
        Like create, but returns null if address is NULL.
      • createSafe

        @Nullable
        public static STBTTKerningentry.Buffer createSafe​(long address,
                                                          int capacity)
        Like create, but returns null if address is NULL.
      • malloc

        public static STBTTKerningentry malloc​(org.lwjgl.system.MemoryStack stack)
        Returns a new STBTTKerningentry instance allocated on the specified MemoryStack.
        Parameters:
        stack - the stack from which to allocate
      • calloc

        public static STBTTKerningentry calloc​(org.lwjgl.system.MemoryStack stack)
        Returns a new STBTTKerningentry instance allocated on the specified MemoryStack and initializes all its bits to zero.
        Parameters:
        stack - the stack from which to allocate
      • malloc

        public static STBTTKerningentry.Buffer malloc​(int capacity,
                                                      org.lwjgl.system.MemoryStack stack)
        Returns a new STBTTKerningentry.Buffer instance allocated on the specified MemoryStack.
        Parameters:
        stack - the stack from which to allocate
        capacity - the buffer capacity
      • calloc

        public static STBTTKerningentry.Buffer calloc​(int capacity,
                                                      org.lwjgl.system.MemoryStack stack)
        Returns a new STBTTKerningentry.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero.
        Parameters:
        stack - the stack from which to allocate
        capacity - the buffer capacity
      • nglyph1

        public static int nglyph1​(long struct)
        Unsafe version of glyph1().
      • nglyph2

        public static int nglyph2​(long struct)
        Unsafe version of glyph2().
      • nadvance

        public static int nadvance​(long struct)
        Unsafe version of advance().