Package org.lwjgl.opencl
Class CLImageFormat
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.opencl.CLImageFormat
-
- All Implemented Interfaces:
java.lang.AutoCloseable,org.lwjgl.system.NativeResource,org.lwjgl.system.Pointer
public class CLImageFormat extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResourceThe image format descriptor struct.Layout
struct cl_image_format { cl_channel_orderimage_channel_order(); cl_channel_typeimage_channel_data_type(); }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classCLImageFormat.BufferAn array ofCLImageFormatstructs.
-
Field Summary
Fields Modifier and Type Field Description static intALIGNOFThe struct alignment in bytes.static intIMAGE_CHANNEL_DATA_TYPE
IMAGE_CHANNEL_ORDERThe struct member offsets.static intSIZEOFThe struct size in bytes.
-
Constructor Summary
Constructors Constructor Description CLImageFormat(java.nio.ByteBuffer container)Creates aCLImageFormatinstance at the current position of the specifiedByteBuffercontainer.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static CLImageFormatcalloc()Returns a newCLImageFormatinstance allocated withmemCalloc.static CLImageFormat.Buffercalloc(int capacity)Returns a newCLImageFormat.Bufferinstance allocated withmemCalloc.static CLImageFormat.Buffercalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newCLImageFormat.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static CLImageFormatcalloc(org.lwjgl.system.MemoryStack stack)Returns a newCLImageFormatinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static CLImageFormatcallocStack()Deprecated.static CLImageFormat.BuffercallocStack(int capacity)Deprecated.static CLImageFormat.BuffercallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Deprecated.static CLImageFormatcallocStack(org.lwjgl.system.MemoryStack stack)Deprecated.static CLImageFormatcreate()Returns a newCLImageFormatinstance allocated withBufferUtils.static CLImageFormat.Buffercreate(int capacity)Returns a newCLImageFormat.Bufferinstance allocated withBufferUtils.static CLImageFormatcreate(long address)Returns a newCLImageFormatinstance for the specified memory address.static CLImageFormat.Buffercreate(long address, int capacity)Create aCLImageFormat.Bufferinstance at the specified memory.static CLImageFormatcreateSafe(long address)static CLImageFormat.BuffercreateSafe(long address, int capacity)intimage_channel_data_type()describes the size of the channel data type.CLImageFormatimage_channel_data_type(int value)Sets the specified value to theimage_channel_data_type()field.intimage_channel_order()specifies the number of channels and the channel layout i.e.CLImageFormatimage_channel_order(int value)Sets the specified value to theimage_channel_order()field.static CLImageFormatmalloc()Returns a newCLImageFormatinstance allocated withmemAlloc.static CLImageFormat.Buffermalloc(int capacity)Returns a newCLImageFormat.Bufferinstance allocated withmemAlloc.static CLImageFormat.Buffermalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newCLImageFormat.Bufferinstance allocated on the specifiedMemoryStack.static CLImageFormatmalloc(org.lwjgl.system.MemoryStack stack)Returns a newCLImageFormatinstance allocated on the specifiedMemoryStack.static CLImageFormatmallocStack()Deprecated.static CLImageFormat.BuffermallocStack(int capacity)Deprecated.static CLImageFormat.BuffermallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Deprecated.static CLImageFormatmallocStack(org.lwjgl.system.MemoryStack stack)Deprecated.static intnimage_channel_data_type(long struct)Unsafe version ofimage_channel_data_type().static voidnimage_channel_data_type(long struct, int value)Unsafe version ofimage_channel_data_type.static intnimage_channel_order(long struct)Unsafe version ofimage_channel_order().static voidnimage_channel_order(long struct, int value)Unsafe version ofimage_channel_order.CLImageFormatset(int image_channel_order, int image_channel_data_type)Initializes this struct with the specified values.CLImageFormatset(CLImageFormat src)Copies the specified struct data to this struct.intsizeof()
-
-
-
Constructor Detail
-
CLImageFormat
public CLImageFormat(java.nio.ByteBuffer container)
Creates aCLImageFormatinstance at the current position of the specifiedByteBuffercontainer. 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:
sizeofin classorg.lwjgl.system.Struct
-
image_channel_order
public int image_channel_order()
specifies the number of channels and the channel layout i.e. the memory layout in which channels are stored in the image
-
image_channel_data_type
public int image_channel_data_type()
describes the size of the channel data type. The number of bits per element determined by theimage_channel_data_typeandimage_channel_ordermust be a power of two.
-
image_channel_order
public CLImageFormat image_channel_order(int value)
Sets the specified value to theimage_channel_order()field.
-
image_channel_data_type
public CLImageFormat image_channel_data_type(int value)
Sets the specified value to theimage_channel_data_type()field.
-
set
public CLImageFormat set(int image_channel_order, int image_channel_data_type)
Initializes this struct with the specified values.
-
set
public CLImageFormat set(CLImageFormat src)
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
public static CLImageFormat malloc()
Returns a newCLImageFormatinstance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static CLImageFormat calloc()
Returns a newCLImageFormatinstance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static CLImageFormat create()
Returns a newCLImageFormatinstance allocated withBufferUtils.
-
create
public static CLImageFormat create(long address)
Returns a newCLImageFormatinstance for the specified memory address.
-
createSafe
@Nullable public static CLImageFormat createSafe(long address)
-
malloc
public static CLImageFormat.Buffer malloc(int capacity)
Returns a newCLImageFormat.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static CLImageFormat.Buffer calloc(int capacity)
Returns a newCLImageFormat.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static CLImageFormat.Buffer create(int capacity)
Returns a newCLImageFormat.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static CLImageFormat.Buffer create(long address, int capacity)
Create aCLImageFormat.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
@Nullable public static CLImageFormat.Buffer createSafe(long address, int capacity)
-
mallocStack
@Deprecated public static CLImageFormat mallocStack()
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead.
-
callocStack
@Deprecated public static CLImageFormat callocStack()
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead.
-
mallocStack
@Deprecated public static CLImageFormat mallocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead.
-
callocStack
@Deprecated public static CLImageFormat callocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead.
-
mallocStack
@Deprecated public static CLImageFormat.Buffer mallocStack(int capacity)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)instead.
-
callocStack
@Deprecated public static CLImageFormat.Buffer callocStack(int capacity)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead.
-
mallocStack
@Deprecated public static CLImageFormat.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)instead.
-
callocStack
@Deprecated public static CLImageFormat.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead.
-
malloc
public static CLImageFormat malloc(org.lwjgl.system.MemoryStack stack)
Returns a newCLImageFormatinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
public static CLImageFormat calloc(org.lwjgl.system.MemoryStack stack)
Returns a newCLImageFormatinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
public static CLImageFormat.Buffer malloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newCLImageFormat.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
calloc
public static CLImageFormat.Buffer calloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newCLImageFormat.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
nimage_channel_order
public static int nimage_channel_order(long struct)
Unsafe version ofimage_channel_order().
-
nimage_channel_data_type
public static int nimage_channel_data_type(long struct)
Unsafe version ofimage_channel_data_type().
-
nimage_channel_order
public static void nimage_channel_order(long struct, int value)Unsafe version ofimage_channel_order.
-
nimage_channel_data_type
public static void nimage_channel_data_type(long struct, int value)Unsafe version ofimage_channel_data_type.
-
-