Class NkFontGlyph.Buffer

All Implemented Interfaces:
AutoCloseable, Iterable<NkFontGlyph>, NativeResource, Pointer
Enclosing class:
NkFontGlyph

public static class NkFontGlyph.Buffer extends StructBuffer<NkFontGlyph,NkFontGlyph.Buffer> implements NativeResource
An array of NkFontGlyph structs.
  • Constructor Details

    • Buffer

      public Buffer(ByteBuffer container)
      Creates a new NkFontGlyph.Buffer instance backed by the specified container.

      Changes to the container's content will be visible to the struct buffer instance and vice versa. The two buffers' position, limit, and mark values will be independent. The new buffer's position will be zero, its capacity and its limit will be the number of bytes remaining in this buffer divided by NkFontGlyph.SIZEOF, and its mark will be undefined.

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

    • Buffer

      public Buffer(long address, int cap)
  • Method Details

    • codepoint

      public int codepoint()
      Returns:
      the value of the codepoint field.
    • xadvance

      public float xadvance()
      Returns:
      the value of the xadvance field.
    • x0

      public float x0()
      Returns:
      the value of the x0 field.
    • y0

      public float y0()
      Returns:
      the value of the y0 field.
    • x1

      public float x1()
      Returns:
      the value of the x1 field.
    • y1

      public float y1()
      Returns:
      the value of the y1 field.
    • w

      public float w()
      Returns:
      the value of the w field.
    • h

      public float h()
      Returns:
      the value of the h field.
    • u0

      public float u0()
      Returns:
      the value of the u0 field.
    • v0

      public float v0()
      Returns:
      the value of the v0 field.
    • u1

      public float u1()
      Returns:
      the value of the u1 field.
    • v1

      public float v1()
      Returns:
      the value of the v1 field.
    • codepoint

      public NkFontGlyph.Buffer codepoint(int value)
      Sets the specified value to the codepoint field.
    • xadvance

      public NkFontGlyph.Buffer xadvance(float value)
      Sets the specified value to the xadvance field.
    • x0

      public NkFontGlyph.Buffer x0(float value)
      Sets the specified value to the x0 field.
    • y0

      public NkFontGlyph.Buffer y0(float value)
      Sets the specified value to the y0 field.
    • x1

      public NkFontGlyph.Buffer x1(float value)
      Sets the specified value to the x1 field.
    • y1

      public NkFontGlyph.Buffer y1(float value)
      Sets the specified value to the y1 field.
    • w

      public NkFontGlyph.Buffer w(float value)
      Sets the specified value to the w field.
    • h

      public NkFontGlyph.Buffer h(float value)
      Sets the specified value to the h field.
    • u0

      public NkFontGlyph.Buffer u0(float value)
      Sets the specified value to the u0 field.
    • v0

      public NkFontGlyph.Buffer v0(float value)
      Sets the specified value to the v0 field.
    • u1

      public NkFontGlyph.Buffer u1(float value)
      Sets the specified value to the u1 field.
    • v1

      public NkFontGlyph.Buffer v1(float value)
      Sets the specified value to the v1 field.