Class EXRHeader

    • Field Detail

      • SIZEOF

        The struct size in bytes.
      • ALIGNOF

        The struct alignment in bytes.
      • PIXEL_ASPECT_RATIO, LINE_ORDER, DATA_WINDOW, DISPLAY_WINDOW, SCREEN_WINDOW_CENTER, SCREEN_WINDOW_WIDTH, CHUNK_COUNT, TILED, TILE_SIZE_X, TILE_SIZE_Y, TILE_LEVEL_MODE, TILE_ROUNDING_MODE, LONG_NAME, NON_IMAGE, MULTIPART, HEADER_LEN, NUM_CUSTOM_ATTRIBUTES, CUSTOM_ATTRIBUTES, CHANNELS, PIXEL_TYPES, NUM_CHANNELS, COMPRESSION_TYPE, REQUESTED_PIXEL_TYPES, NAME

        The struct member offsets.
    • Constructor Detail

      • EXRHeader

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

        public float pixel_aspect_ratio()
        Returns:
        the value of the pixel_aspect_ratio field.
      • line_order

        public int line_order()
        Returns:
        the value of the line_order field.
      • data_window

        public EXRBox2i data_window()
        Returns:
        a EXRBox2i view of the data_window field.
      • display_window

        public EXRBox2i display_window()
        Returns:
        a EXRBox2i view of the display_window field.
      • screen_window_center

        public java.nio.FloatBuffer screen_window_center()
        Returns:
        a FloatBuffer view of the screen_window_center field.
      • screen_window_center

        public float screen_window_center​(int index)
        Returns:
        the value at the specified index of the screen_window_center field.
      • screen_window_width

        public float screen_window_width()
        Returns:
        the value of the screen_window_width field.
      • chunk_count

        public int chunk_count()
        Returns:
        the value of the chunk_count field.
      • tiled

        public boolean tiled()
        Returns:
        the value of the tiled field.
      • tile_size_x

        public int tile_size_x()
        Returns:
        the value of the tile_size_x field.
      • tile_size_y

        public int tile_size_y()
        Returns:
        the value of the tile_size_y field.
      • tile_level_mode

        public int tile_level_mode()
        Returns:
        the value of the tile_level_mode field.
      • tile_rounding_mode

        public int tile_rounding_mode()
        Returns:
        the value of the tile_rounding_mode field.
      • long_name

        public boolean long_name()
        Returns:
        the value of the long_name field.
      • non_image

        public boolean non_image()
        For a single-part file, agree with the version field bit 11. For a multi-part file, it is consistent with the type of part.
      • multipart

        public boolean multipart()
        Returns:
        the value of the multipart field.
      • header_len

        public int header_len()
        Returns:
        the value of the header_len field.
      • num_custom_attributes

        public int num_custom_attributes()
        number of EXRAttribute in the custom_attributes array
      • custom_attributes

        @Nullable
        public EXRAttribute.Buffer custom_attributes()
        custom attributes (excludes required attributes, e.g. `channels`, `compression`, etc)
      • pixel_types

        public java.nio.IntBuffer pixel_types()
        loaded pixel type (TINYEXR_PIXELTYPE_*) of images for each channel. This is overwritten with requested_pixel_types when loading.
      • num_channels

        public int num_channels()
        Returns:
        the value of the num_channels field.
      • compression_type

        public int compression_type()
        compression type (TINYEXR_COMPRESSIONTYPE_*)
      • requested_pixel_types

        public java.nio.IntBuffer requested_pixel_types()
        filled initially by ParseEXRHeaderFrom(Memory|File), then users can edit it (only valid for HALF pixel type channel)
      • pixel_aspect_ratio

        public EXRHeader pixel_aspect_ratio​(float value)
        Sets the specified value to the pixel_aspect_ratio field.
      • line_order

        public EXRHeader line_order​(int value)
        Sets the specified value to the line_order field.
      • data_window

        public EXRHeader data_window​(java.util.function.Consumer<EXRBox2i> consumer)
        Passes the data_window field to the specified Consumer.
      • display_window

        public EXRHeader display_window​(EXRBox2i value)
        Copies the specified EXRBox2i to the display_window field.
      • display_window

        public EXRHeader display_window​(java.util.function.Consumer<EXRBox2i> consumer)
        Passes the display_window field to the specified Consumer.
      • screen_window_center

        public EXRHeader screen_window_center​(java.nio.FloatBuffer value)
        Copies the specified FloatBuffer to the screen_window_center field.
      • screen_window_center

        public EXRHeader screen_window_center​(int index,
                                              float value)
        Sets the specified value at the specified index of the screen_window_center field.
      • screen_window_width

        public EXRHeader screen_window_width​(float value)
        Sets the specified value to the screen_window_width field.
      • chunk_count

        public EXRHeader chunk_count​(int value)
        Sets the specified value to the chunk_count field.
      • tiled

        public EXRHeader tiled​(boolean value)
        Sets the specified value to the tiled field.
      • tile_size_x

        public EXRHeader tile_size_x​(int value)
        Sets the specified value to the tile_size_x field.
      • tile_size_y

        public EXRHeader tile_size_y​(int value)
        Sets the specified value to the tile_size_y field.
      • tile_level_mode

        public EXRHeader tile_level_mode​(int value)
        Sets the specified value to the tile_level_mode field.
      • tile_rounding_mode

        public EXRHeader tile_rounding_mode​(int value)
        Sets the specified value to the tile_rounding_mode field.
      • long_name

        public EXRHeader long_name​(boolean value)
        Sets the specified value to the long_name field.
      • non_image

        public EXRHeader non_image​(boolean value)
        Sets the specified value to the non_image() field.
      • multipart

        public EXRHeader multipart​(boolean value)
        Sets the specified value to the multipart field.
      • header_len

        public EXRHeader header_len​(int value)
        Sets the specified value to the header_len field.
      • pixel_types

        public EXRHeader pixel_types​(java.nio.IntBuffer value)
        Sets the address of the specified IntBuffer to the pixel_types() field.
      • num_channels

        public EXRHeader num_channels​(int value)
        Sets the specified value to the num_channels field.
      • requested_pixel_types

        public EXRHeader requested_pixel_types​(java.nio.IntBuffer value)
        Sets the address of the specified IntBuffer to the requested_pixel_types() field.
      • name

        public EXRHeader name​(java.nio.ByteBuffer value)
        Copies the specified encoded string to the name() field.
      • set

        public EXRHeader set​(float pixel_aspect_ratio,
                             int line_order,
                             EXRBox2i data_window,
                             EXRBox2i display_window,
                             java.nio.FloatBuffer screen_window_center,
                             float screen_window_width,
                             int chunk_count,
                             boolean tiled,
                             int tile_size_x,
                             int tile_size_y,
                             int tile_level_mode,
                             int tile_rounding_mode,
                             boolean long_name,
                             boolean non_image,
                             boolean multipart,
                             int header_len,
                             int num_custom_attributes,
                             @Nullable
                             EXRAttribute.Buffer custom_attributes,
                             EXRChannelInfo.Buffer channels,
                             java.nio.IntBuffer pixel_types,
                             int num_channels,
                             int compression_type,
                             java.nio.IntBuffer requested_pixel_types,
                             java.nio.ByteBuffer name)
        Initializes this struct with the specified values.
      • set

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

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

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

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

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

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

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

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

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

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

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

        @Deprecated
        public static EXRHeader mallocStack()
        Deprecated.
        Deprecated for removal in 3.4.0. Use malloc(MemoryStack) instead.
      • callocStack

        @Deprecated
        public static EXRHeader callocStack()
        Deprecated.
        Deprecated for removal in 3.4.0. Use calloc(MemoryStack) instead.
      • mallocStack

        @Deprecated
        public static EXRHeader mallocStack​(org.lwjgl.system.MemoryStack stack)
        Deprecated.
        Deprecated for removal in 3.4.0. Use malloc(MemoryStack) instead.
      • callocStack

        @Deprecated
        public static EXRHeader callocStack​(org.lwjgl.system.MemoryStack stack)
        Deprecated.
        Deprecated for removal in 3.4.0. Use calloc(MemoryStack) instead.
      • mallocStack

        @Deprecated
        public static EXRHeader.Buffer mallocStack​(int capacity,
                                                   org.lwjgl.system.MemoryStack stack)
        Deprecated.
        Deprecated for removal in 3.4.0. Use malloc(int, MemoryStack) instead.
      • callocStack

        @Deprecated
        public static EXRHeader.Buffer callocStack​(int capacity,
                                                   org.lwjgl.system.MemoryStack stack)
        Deprecated.
        Deprecated for removal in 3.4.0. Use calloc(int, MemoryStack) instead.
      • malloc

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

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

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

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

        public static float npixel_aspect_ratio​(long struct)
        Unsafe version of pixel_aspect_ratio().
      • nline_order

        public static int nline_order​(long struct)
        Unsafe version of line_order().
      • nscreen_window_center

        public static java.nio.FloatBuffer nscreen_window_center​(long struct)
        Unsafe version of screen_window_center().
      • nscreen_window_center

        public static float nscreen_window_center​(long struct,
                                                  int index)
        Unsafe version of screen_window_center.
      • nscreen_window_width

        public static float nscreen_window_width​(long struct)
        Unsafe version of screen_window_width().
      • nchunk_count

        public static int nchunk_count​(long struct)
        Unsafe version of chunk_count().
      • ntiled

        public static int ntiled​(long struct)
        Unsafe version of tiled().
      • ntile_size_x

        public static int ntile_size_x​(long struct)
        Unsafe version of tile_size_x().
      • ntile_size_y

        public static int ntile_size_y​(long struct)
        Unsafe version of tile_size_y().
      • ntile_level_mode

        public static int ntile_level_mode​(long struct)
        Unsafe version of tile_level_mode().
      • ntile_rounding_mode

        public static int ntile_rounding_mode​(long struct)
        Unsafe version of tile_rounding_mode().
      • nlong_name

        public static int nlong_name​(long struct)
        Unsafe version of long_name().
      • nnon_image

        public static int nnon_image​(long struct)
        Unsafe version of non_image().
      • nmultipart

        public static int nmultipart​(long struct)
        Unsafe version of multipart().
      • nheader_len

        public static int nheader_len​(long struct)
        Unsafe version of header_len().
      • nnum_custom_attributes

        public static int nnum_custom_attributes​(long struct)
        Unsafe version of num_custom_attributes().
      • npixel_types

        public static java.nio.IntBuffer npixel_types​(long struct)
        Unsafe version of pixel_types.
      • nnum_channels

        public static int nnum_channels​(long struct)
        Unsafe version of num_channels().
      • ncompression_type

        public static int ncompression_type​(long struct)
        Unsafe version of compression_type().
      • nrequested_pixel_types

        public static java.nio.IntBuffer nrequested_pixel_types​(long struct)
        Unsafe version of requested_pixel_types.
      • nname

        public static java.nio.ByteBuffer nname​(long struct)
        Unsafe version of name().
      • nnameString

        public static java.lang.String nnameString​(long struct)
        Unsafe version of nameString().
      • npixel_aspect_ratio

        public static void npixel_aspect_ratio​(long struct,
                                               float value)
        Unsafe version of pixel_aspect_ratio.
      • nline_order

        public static void nline_order​(long struct,
                                       int value)
        Unsafe version of line_order.
      • ndata_window

        public static void ndata_window​(long struct,
                                        EXRBox2i value)
        Unsafe version of data_window.
      • ndisplay_window

        public static void ndisplay_window​(long struct,
                                           EXRBox2i value)
        Unsafe version of display_window.
      • nscreen_window_center

        public static void nscreen_window_center​(long struct,
                                                 java.nio.FloatBuffer value)
        Unsafe version of screen_window_center.
      • nscreen_window_center

        public static void nscreen_window_center​(long struct,
                                                 int index,
                                                 float value)
        Unsafe version of screen_window_center.
      • nscreen_window_width

        public static void nscreen_window_width​(long struct,
                                                float value)
        Unsafe version of screen_window_width.
      • nchunk_count

        public static void nchunk_count​(long struct,
                                        int value)
        Unsafe version of chunk_count.
      • ntiled

        public static void ntiled​(long struct,
                                  int value)
        Unsafe version of tiled.
      • ntile_size_x

        public static void ntile_size_x​(long struct,
                                        int value)
        Unsafe version of tile_size_x.
      • ntile_size_y

        public static void ntile_size_y​(long struct,
                                        int value)
        Unsafe version of tile_size_y.
      • ntile_level_mode

        public static void ntile_level_mode​(long struct,
                                            int value)
        Unsafe version of tile_level_mode.
      • ntile_rounding_mode

        public static void ntile_rounding_mode​(long struct,
                                               int value)
        Unsafe version of tile_rounding_mode.
      • nlong_name

        public static void nlong_name​(long struct,
                                      int value)
        Unsafe version of long_name.
      • nnon_image

        public static void nnon_image​(long struct,
                                      int value)
        Unsafe version of non_image.
      • nmultipart

        public static void nmultipart​(long struct,
                                      int value)
        Unsafe version of multipart.
      • nheader_len

        public static void nheader_len​(long struct,
                                       int value)
        Unsafe version of header_len.
      • nnum_custom_attributes

        public static void nnum_custom_attributes​(long struct,
                                                  int value)
        Sets the specified value to the num_custom_attributes field of the specified struct.
      • npixel_types

        public static void npixel_types​(long struct,
                                        java.nio.IntBuffer value)
        Unsafe version of pixel_types.
      • nnum_channels

        public static void nnum_channels​(long struct,
                                         int value)
        Sets the specified value to the num_channels field of the specified struct.
      • ncompression_type

        public static void ncompression_type​(long struct,
                                             int value)
        Unsafe version of compression_type.
      • nrequested_pixel_types

        public static void nrequested_pixel_types​(long struct,
                                                  java.nio.IntBuffer value)
        Unsafe version of requested_pixel_types.
      • nname

        public static void nname​(long struct,
                                 java.nio.ByteBuffer value)
        Unsafe version of name.
      • validate

        public static void validate​(long struct)
        Validates pointer members that should not be NULL.
        Parameters:
        struct - the struct to validate