Package org.lwjgl.stb

Class STBVorbisComment

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

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

    Layout

    
     struct stb_vorbis_comment {
         char * vendor;
         int comment_list_length;
         char ** comment_list;
     }
    • Field Detail

      • SIZEOF

        The struct size in bytes.
      • ALIGNOF

        The struct alignment in bytes.
      • VENDOR, COMMENT_LIST_LENGTH, COMMENT_LIST

        The struct member offsets.
    • Constructor Detail

      • STBVorbisComment

        public STBVorbisComment​(java.nio.ByteBuffer container)
        Creates a STBVorbisComment 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
      • vendor

        public java.nio.ByteBuffer vendor()
        Returns:
        a ByteBuffer view of the null-terminated string pointed to by the vendor field.
      • vendorString

        public java.lang.String vendorString()
        Returns:
        the null-terminated string pointed to by the vendor field.
      • comment_list_length

        public int comment_list_length()
        Returns:
        the value of the comment_list_length field.
      • comment_list

        public org.lwjgl.PointerBuffer comment_list()
        Returns:
        a PointerBuffer view of the data pointed to by the comment_list field.
      • malloc

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

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

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

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

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

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

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

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

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

        public static STBVorbisComment.Buffer calloc​(int capacity,
                                                     org.lwjgl.system.MemoryStack stack)
        Returns a new STBVorbisComment.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
      • nvendor

        public static java.nio.ByteBuffer nvendor​(long struct)
        Unsafe version of vendor().
      • nvendorString

        public static java.lang.String nvendorString​(long struct)
        Unsafe version of vendorString().
      • ncomment_list_length

        public static int ncomment_list_length​(long struct)
        Unsafe version of comment_list_length().
      • ncomment_list

        public static org.lwjgl.PointerBuffer ncomment_list​(long struct)
        Unsafe version of comment_list.