Class ExrPartInfo

All Implemented Interfaces:
AutoCloseable, NativeResource, Pointer

public class ExrPartInfo extends Struct<ExrPartInfo> implements NativeResource
struct ExrPartInfo {
    char const * name;
    char const * type_string;
    uint32_t part_type;
    int32_t width;
    int32_t height;
    uint32_t num_channels;
    uint32_t compression;
    uint32_t flags;
}
  • Field Details

    • SIZEOF

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

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

      public static final int NAME
      The struct member offsets.
    • TYPE_STRING

      public static final int TYPE_STRING
      The struct member offsets.
    • PART_TYPE

      public static final int PART_TYPE
      The struct member offsets.
    • WIDTH

      public static final int WIDTH
      The struct member offsets.
    • HEIGHT

      public static final int HEIGHT
      The struct member offsets.
    • NUM_CHANNELS

      public static final int NUM_CHANNELS
      The struct member offsets.
    • COMPRESSION

      public static final int COMPRESSION
      The struct member offsets.
    • FLAGS

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

    • ExrPartInfo

      public ExrPartInfo(ByteBuffer container)
      Creates a ExrPartInfo 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<ExrPartInfo>
    • name

      @NativeType("char const *") public @Nullable ByteBuffer name()
      Returns:
      a ByteBuffer view of the null-terminated string pointed to by the name field.
    • nameString

      @NativeType("char const *") public @Nullable String nameString()
      Returns:
      the null-terminated string pointed to by the name field.
    • type_string

      @NativeType("char const *") public ByteBuffer type_string()
      Returns:
      a ByteBuffer view of the null-terminated string pointed to by the type_string field.
    • type_stringString

      @NativeType("char const *") public String type_stringString()
      Returns:
      the null-terminated string pointed to by the type_string field.
    • part_type

      @NativeType("uint32_t") public int part_type()
      Returns:
      the value of the part_type field.
    • width

      @NativeType("int32_t") public int width()
      Returns:
      the value of the width field.
    • height

      @NativeType("int32_t") public int height()
      Returns:
      the value of the height field.
    • num_channels

      @NativeType("uint32_t") public int num_channels()
      Returns:
      the value of the num_channels field.
    • compression

      @NativeType("uint32_t") public int compression()
      Returns:
      the value of the compression field.
    • flags

      @NativeType("uint32_t") public int flags()
      Returns:
      the value of the flags field.
    • name

      public ExrPartInfo name(@NativeType("char const *") @Nullable ByteBuffer value)
      Sets the address of the specified encoded string to the name field.
    • type_string

      public ExrPartInfo type_string(@NativeType("char const *") ByteBuffer value)
      Sets the address of the specified encoded string to the type_string field.
    • part_type

      public ExrPartInfo part_type(@NativeType("uint32_t") int value)
      Sets the specified value to the part_type field.
    • width

      public ExrPartInfo width(@NativeType("int32_t") int value)
      Sets the specified value to the width field.
    • height

      public ExrPartInfo height(@NativeType("int32_t") int value)
      Sets the specified value to the height field.
    • num_channels

      public ExrPartInfo num_channels(@NativeType("uint32_t") int value)
      Sets the specified value to the num_channels field.
    • compression

      public ExrPartInfo compression(@NativeType("uint32_t") int value)
      Sets the specified value to the compression field.
    • flags

      public ExrPartInfo flags(@NativeType("uint32_t") int value)
      Sets the specified value to the flags field.
    • set

      public ExrPartInfo set(@Nullable ByteBuffer name, ByteBuffer type_string, int part_type, int width, int height, int num_channels, int compression, int flags)
      Initializes this struct with the specified values.
    • set

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      public static ExrPartInfo.Buffer calloc(int capacity, MemoryStack stack)
      Returns a new ExrPartInfo.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
    • nname

      public static @Nullable ByteBuffer nname(long struct)
      Unsafe version of name().
    • nnameString

      public static @Nullable String nnameString(long struct)
      Unsafe version of nameString().
    • ntype_string

      public static ByteBuffer ntype_string(long struct)
      Unsafe version of type_string().
    • ntype_stringString

      public static String ntype_stringString(long struct)
      Unsafe version of type_stringString().
    • npart_type

      public static int npart_type(long struct)
      Unsafe version of part_type().
    • nwidth

      public static int nwidth(long struct)
      Unsafe version of width().
    • nheight

      public static int nheight(long struct)
      Unsafe version of height().
    • nnum_channels

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

      public static int ncompression(long struct)
      Unsafe version of compression().
    • nflags

      public static int nflags(long struct)
      Unsafe version of flags().
    • nname

      public static void nname(long struct, @Nullable ByteBuffer value)
      Unsafe version of name.
    • ntype_string

      public static void ntype_string(long struct, ByteBuffer value)
      Unsafe version of type_string.
    • npart_type

      public static void npart_type(long struct, int value)
      Unsafe version of part_type.
    • nwidth

      public static void nwidth(long struct, int value)
      Unsafe version of width.
    • nheight

      public static void nheight(long struct, int value)
      Unsafe version of height.
    • nnum_channels

      public static void nnum_channels(long struct, int value)
      Unsafe version of num_channels.
    • ncompression

      public static void ncompression(long struct, int value)
      Unsafe version of compression.
    • nflags

      public static void nflags(long struct, int value)
      Unsafe version of flags.
    • validate

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