Class FT_BBox

All Implemented Interfaces:
AutoCloseable, NativeResource, Pointer

public class FT_BBox extends Struct<FT_BBox> implements NativeResource

 struct FT_BBox {
     FT_Pos xMin;
     FT_Pos yMin;
     FT_Pos xMax;
     FT_Pos yMax;
 }
  • Field Details

    • SIZEOF

      public static final int SIZEOF
      The struct size in bytes.
    • ALIGNOF

      public static final int ALIGNOF
      The struct alignment in bytes.
    • XMIN

      public static final int XMIN
      The struct member offsets.
    • YMIN

      public static final int YMIN
      The struct member offsets.
    • XMAX

      public static final int XMAX
      The struct member offsets.
    • YMAX

      public static final int YMAX
      The struct member offsets.
  • Constructor Details

    • FT_BBox

      public FT_BBox(ByteBuffer container)
      Creates a FT_BBox 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 Details

    • sizeof

      public int sizeof()
      Description copied from class: Struct
      Returns sizeof(struct).
      Specified by:
      sizeof in class Struct<FT_BBox>
    • xMin

      public long xMin()
      Returns:
      the value of the xMin field.
    • yMin

      public long yMin()
      Returns:
      the value of the yMin field.
    • xMax

      public long xMax()
      Returns:
      the value of the xMax field.
    • yMax

      public long yMax()
      Returns:
      the value of the yMax field.
    • xMin

      public FT_BBox xMin(long value)
      Sets the specified value to the xMin field.
    • yMin

      public FT_BBox yMin(long value)
      Sets the specified value to the yMin field.
    • xMax

      public FT_BBox xMax(long value)
      Sets the specified value to the xMax field.
    • yMax

      public FT_BBox yMax(long value)
      Sets the specified value to the yMax field.
    • set

      public FT_BBox set(long xMin, long yMin, long xMax, long yMax)
      Initializes this struct with the specified values.
    • set

      public FT_BBox set(FT_BBox src)
      Copies the specified struct data to this struct.
      Parameters:
      src - the source struct
      Returns:
      this struct
    • malloc

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

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

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

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

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

      public static FT_BBox.Buffer malloc(int capacity)
      Returns a new FT_BBox.Buffer instance allocated with memAlloc. The instance must be explicitly freed.
      Parameters:
      capacity - the buffer capacity
    • calloc

      public static FT_BBox.Buffer calloc(int capacity)
      Returns a new FT_BBox.Buffer instance allocated with memCalloc. The instance must be explicitly freed.
      Parameters:
      capacity - the buffer capacity
    • create

      public static FT_BBox.Buffer create(int capacity)
      Returns a new FT_BBox.Buffer instance allocated with BufferUtils.
      Parameters:
      capacity - the buffer capacity
    • create

      public static FT_BBox.Buffer create(long address, int capacity)
      Create a FT_BBox.Buffer instance at the specified memory.
      Parameters:
      address - the memory address
      capacity - the buffer capacity
    • createSafe

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

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

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

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

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

      public static long nxMin(long struct)
      Unsafe version of xMin().
    • nyMin

      public static long nyMin(long struct)
      Unsafe version of yMin().
    • nxMax

      public static long nxMax(long struct)
      Unsafe version of xMax().
    • nyMax

      public static long nyMax(long struct)
      Unsafe version of yMax().
    • nxMin

      public static void nxMin(long struct, long value)
      Unsafe version of xMin.
    • nyMin

      public static void nyMin(long struct, long value)
      Unsafe version of yMin.
    • nxMax

      public static void nxMax(long struct, long value)
      Unsafe version of xMax.
    • nyMax

      public static void nyMax(long struct, long value)
      Unsafe version of yMax.