Package org.lwjgl.cuda
Class CUDA_KERNEL_NODE_PARAMS
java.lang.Object
org.lwjgl.system.Pointer.Default
org.lwjgl.system.Struct<CUDA_KERNEL_NODE_PARAMS>
org.lwjgl.cuda.CUDA_KERNEL_NODE_PARAMS
- All Implemented Interfaces:
AutoCloseable,org.lwjgl.system.NativeResource,org.lwjgl.system.Pointer
public class CUDA_KERNEL_NODE_PARAMS
extends org.lwjgl.system.Struct<CUDA_KERNEL_NODE_PARAMS>
implements org.lwjgl.system.NativeResource
Layout
struct CUDA_KERNEL_NODE_PARAMS {
CUfunction func;
unsigned int gridDimX;
unsigned int gridDimY;
unsigned int gridDimZ;
unsigned int blockDimX;
unsigned int blockDimY;
unsigned int blockDimZ;
unsigned int sharedMemBytes;
void ** kernelParams;
void ** extra;
}-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class org.lwjgl.system.Struct
org.lwjgl.system.Struct.StructValidationNested classes/interfaces inherited from interface org.lwjgl.system.Pointer
org.lwjgl.system.Pointer.Default -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThe struct alignment in bytes.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct size in bytes.Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE -
Constructor Summary
ConstructorsConstructorDescriptionCUDA_KERNEL_NODE_PARAMS(ByteBuffer container) Creates aCUDA_KERNEL_NODE_PARAMSinstance at the current position of the specifiedByteBuffercontainer. -
Method Summary
Modifier and TypeMethodDescriptionintblockDimX(int value) Sets the specified value to theblockDimXfield.intblockDimY(int value) Sets the specified value to theblockDimYfield.intblockDimZ(int value) Sets the specified value to theblockDimZfield.static CUDA_KERNEL_NODE_PARAMScalloc()Returns a newCUDA_KERNEL_NODE_PARAMSinstance allocated withmemCalloc.calloc(int capacity) Returns a newCUDA_KERNEL_NODE_PARAMS.Bufferinstance allocated withmemCalloc.calloc(int capacity, org.lwjgl.system.MemoryStack stack) Returns a newCUDA_KERNEL_NODE_PARAMS.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static CUDA_KERNEL_NODE_PARAMScalloc(org.lwjgl.system.MemoryStack stack) Returns a newCUDA_KERNEL_NODE_PARAMSinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static CUDA_KERNEL_NODE_PARAMSDeprecated.callocStack(int capacity) Deprecated.callocStack(int capacity, org.lwjgl.system.MemoryStack stack) Deprecated.static CUDA_KERNEL_NODE_PARAMScallocStack(org.lwjgl.system.MemoryStack stack) Deprecated.static CUDA_KERNEL_NODE_PARAMScreate()Returns a newCUDA_KERNEL_NODE_PARAMSinstance allocated withBufferUtils.create(int capacity) Returns a newCUDA_KERNEL_NODE_PARAMS.Bufferinstance allocated withBufferUtils.static CUDA_KERNEL_NODE_PARAMScreate(long address) Returns a newCUDA_KERNEL_NODE_PARAMSinstance for the specified memory address.create(long address, int capacity) Create aCUDA_KERNEL_NODE_PARAMS.Bufferinstance at the specified memory.static @Nullable CUDA_KERNEL_NODE_PARAMScreateSafe(long address) static @Nullable CUDA_KERNEL_NODE_PARAMS.BuffercreateSafe(long address, int capacity) @Nullable org.lwjgl.PointerBufferextra(int capacity) extra(@Nullable org.lwjgl.PointerBuffer value) Sets the address of the specifiedPointerBufferto theextrafield.longfunc()func(long value) Sets the specified value to thefuncfield.intgridDimX()gridDimX(int value) Sets the specified value to thegridDimXfield.intgridDimY()gridDimY(int value) Sets the specified value to thegridDimYfield.intgridDimZ()gridDimZ(int value) Sets the specified value to thegridDimZfield.@Nullable org.lwjgl.PointerBufferkernelParams(int capacity) kernelParams(@Nullable org.lwjgl.PointerBuffer value) Sets the address of the specifiedPointerBufferto thekernelParamsfield.static CUDA_KERNEL_NODE_PARAMSmalloc()Returns a newCUDA_KERNEL_NODE_PARAMSinstance allocated withmemAlloc.malloc(int capacity) Returns a newCUDA_KERNEL_NODE_PARAMS.Bufferinstance allocated withmemAlloc.malloc(int capacity, org.lwjgl.system.MemoryStack stack) Returns a newCUDA_KERNEL_NODE_PARAMS.Bufferinstance allocated on the specifiedMemoryStack.static CUDA_KERNEL_NODE_PARAMSmalloc(org.lwjgl.system.MemoryStack stack) Returns a newCUDA_KERNEL_NODE_PARAMSinstance allocated on the specifiedMemoryStack.static CUDA_KERNEL_NODE_PARAMSDeprecated.mallocStack(int capacity) Deprecated.mallocStack(int capacity, org.lwjgl.system.MemoryStack stack) Deprecated.static CUDA_KERNEL_NODE_PARAMSmallocStack(org.lwjgl.system.MemoryStack stack) Deprecated.static intnblockDimX(long struct) Unsafe version ofblockDimX().static voidnblockDimX(long struct, int value) Unsafe version ofblockDimX.static intnblockDimY(long struct) Unsafe version ofblockDimY().static voidnblockDimY(long struct, int value) Unsafe version ofblockDimY.static intnblockDimZ(long struct) Unsafe version ofblockDimZ().static voidnblockDimZ(long struct, int value) Unsafe version ofblockDimZ.static @Nullable org.lwjgl.PointerBuffernextra(long struct, int capacity) Unsafe version ofextra.static voidnextra(long struct, @Nullable org.lwjgl.PointerBuffer value) Unsafe version ofextra.static longnfunc(long struct) Unsafe version offunc().static voidnfunc(long struct, long value) Unsafe version offunc.static intngridDimX(long struct) Unsafe version ofgridDimX().static voidngridDimX(long struct, int value) Unsafe version ofgridDimX.static intngridDimY(long struct) Unsafe version ofgridDimY().static voidngridDimY(long struct, int value) Unsafe version ofgridDimY.static intngridDimZ(long struct) Unsafe version ofgridDimZ().static voidngridDimZ(long struct, int value) Unsafe version ofgridDimZ.static @Nullable org.lwjgl.PointerBuffernkernelParams(long struct, int capacity) Unsafe version ofkernelParams.static voidnkernelParams(long struct, @Nullable org.lwjgl.PointerBuffer value) Unsafe version ofkernelParams.static intnsharedMemBytes(long struct) Unsafe version ofsharedMemBytes().static voidnsharedMemBytes(long struct, int value) Unsafe version ofsharedMemBytes.set(long func, int gridDimX, int gridDimY, int gridDimZ, int blockDimX, int blockDimY, int blockDimZ, int sharedMemBytes, @Nullable org.lwjgl.PointerBuffer kernelParams, @Nullable org.lwjgl.PointerBuffer extra) Initializes this struct with the specified values.Copies the specified struct data to this struct.intsharedMemBytes(int value) Sets the specified value to thesharedMemBytesfield.intsizeof()Methods inherited from class org.lwjgl.system.Struct
clear, free, isNull, validate, validateMethods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toStringMethods inherited from interface org.lwjgl.system.NativeResource
close, free
-
Field Details
-
SIZEOF
public static final int SIZEOFThe struct size in bytes. -
ALIGNOF
public static final int ALIGNOFThe struct alignment in bytes. -
FUNC
public static final int FUNCThe struct member offsets. -
GRIDDIMX
public static final int GRIDDIMXThe struct member offsets. -
GRIDDIMY
public static final int GRIDDIMYThe struct member offsets. -
GRIDDIMZ
public static final int GRIDDIMZThe struct member offsets. -
BLOCKDIMX
public static final int BLOCKDIMXThe struct member offsets. -
BLOCKDIMY
public static final int BLOCKDIMYThe struct member offsets. -
BLOCKDIMZ
public static final int BLOCKDIMZThe struct member offsets. -
SHAREDMEMBYTES
public static final int SHAREDMEMBYTESThe struct member offsets. -
KERNELPARAMS
public static final int KERNELPARAMSThe struct member offsets. -
EXTRA
public static final int EXTRAThe struct member offsets.
-
-
Constructor Details
-
CUDA_KERNEL_NODE_PARAMS
Creates aCUDA_KERNEL_NODE_PARAMSinstance 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 Details
-
sizeof
public int sizeof()- Specified by:
sizeofin classorg.lwjgl.system.Struct<CUDA_KERNEL_NODE_PARAMS>
-
func
public long func()- Returns:
- the value of the
funcfield.
-
gridDimX
public int gridDimX()- Returns:
- the value of the
gridDimXfield.
-
gridDimY
public int gridDimY()- Returns:
- the value of the
gridDimYfield.
-
gridDimZ
public int gridDimZ()- Returns:
- the value of the
gridDimZfield.
-
blockDimX
public int blockDimX()- Returns:
- the value of the
blockDimXfield.
-
blockDimY
public int blockDimY()- Returns:
- the value of the
blockDimYfield.
-
blockDimZ
public int blockDimZ()- Returns:
- the value of the
blockDimZfield.
-
kernelParams
public @Nullable org.lwjgl.PointerBuffer kernelParams(int capacity) - Parameters:
capacity- the number of elements in the returned buffer- Returns:
- a
PointerBufferview of the data pointed to by thekernelParamsfield.
-
extra
public @Nullable org.lwjgl.PointerBuffer extra(int capacity) - Parameters:
capacity- the number of elements in the returned buffer- Returns:
- a
PointerBufferview of the data pointed to by theextrafield.
-
func
Sets the specified value to thefuncfield. -
gridDimX
Sets the specified value to thegridDimXfield. -
gridDimY
Sets the specified value to thegridDimYfield. -
gridDimZ
Sets the specified value to thegridDimZfield. -
blockDimX
Sets the specified value to theblockDimXfield. -
blockDimY
Sets the specified value to theblockDimYfield. -
blockDimZ
Sets the specified value to theblockDimZfield. -
kernelParams
Sets the address of the specifiedPointerBufferto thekernelParamsfield. -
extra
Sets the address of the specifiedPointerBufferto theextrafield. -
set
public CUDA_KERNEL_NODE_PARAMS set(long func, int gridDimX, int gridDimY, int gridDimZ, int blockDimX, int blockDimY, int blockDimZ, int sharedMemBytes, @Nullable org.lwjgl.PointerBuffer kernelParams, @Nullable org.lwjgl.PointerBuffer extra) Initializes this struct with the specified values. -
set
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
Returns a newCUDA_KERNEL_NODE_PARAMSinstance allocated withmemAlloc. The instance must be explicitly freed. -
calloc
Returns a newCUDA_KERNEL_NODE_PARAMSinstance allocated withmemCalloc. The instance must be explicitly freed. -
create
Returns a newCUDA_KERNEL_NODE_PARAMSinstance allocated withBufferUtils. -
create
Returns a newCUDA_KERNEL_NODE_PARAMSinstance for the specified memory address. -
createSafe
-
malloc
Returns a newCUDA_KERNEL_NODE_PARAMS.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
Returns a newCUDA_KERNEL_NODE_PARAMS.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
Returns a newCUDA_KERNEL_NODE_PARAMS.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
Create aCUDA_KERNEL_NODE_PARAMS.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
-
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead. -
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead. -
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead. -
mallocStack
@Deprecated public static CUDA_KERNEL_NODE_PARAMS.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 CUDA_KERNEL_NODE_PARAMS.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack) Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead. -
malloc
Returns a newCUDA_KERNEL_NODE_PARAMSinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
Returns a newCUDA_KERNEL_NODE_PARAMSinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
public static CUDA_KERNEL_NODE_PARAMS.Buffer malloc(int capacity, org.lwjgl.system.MemoryStack stack) Returns a newCUDA_KERNEL_NODE_PARAMS.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
capacity- the buffer capacitystack- the stack from which to allocate
-
calloc
public static CUDA_KERNEL_NODE_PARAMS.Buffer calloc(int capacity, org.lwjgl.system.MemoryStack stack) Returns a newCUDA_KERNEL_NODE_PARAMS.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
capacity- the buffer capacitystack- the stack from which to allocate
-
nfunc
public static long nfunc(long struct) Unsafe version offunc(). -
ngridDimX
public static int ngridDimX(long struct) Unsafe version ofgridDimX(). -
ngridDimY
public static int ngridDimY(long struct) Unsafe version ofgridDimY(). -
ngridDimZ
public static int ngridDimZ(long struct) Unsafe version ofgridDimZ(). -
nblockDimX
public static int nblockDimX(long struct) Unsafe version ofblockDimX(). -
nblockDimY
public static int nblockDimY(long struct) Unsafe version ofblockDimY(). -
nblockDimZ
public static int nblockDimZ(long struct) Unsafe version ofblockDimZ(). -
nkernelParams
public static @Nullable org.lwjgl.PointerBuffer nkernelParams(long struct, int capacity) Unsafe version ofkernelParams. -
nextra
public static @Nullable org.lwjgl.PointerBuffer nextra(long struct, int capacity) Unsafe version ofextra. -
nfunc
public static void nfunc(long struct, long value) Unsafe version offunc. -
ngridDimX
public static void ngridDimX(long struct, int value) Unsafe version ofgridDimX. -
ngridDimY
public static void ngridDimY(long struct, int value) Unsafe version ofgridDimY. -
ngridDimZ
public static void ngridDimZ(long struct, int value) Unsafe version ofgridDimZ. -
nblockDimX
public static void nblockDimX(long struct, int value) Unsafe version ofblockDimX. -
nblockDimY
public static void nblockDimY(long struct, int value) Unsafe version ofblockDimY. -
nblockDimZ
public static void nblockDimZ(long struct, int value) Unsafe version ofblockDimZ. -
nkernelParams
public static void nkernelParams(long struct, @Nullable org.lwjgl.PointerBuffer value) Unsafe version ofkernelParams. -
nextra
public static void nextra(long struct, @Nullable org.lwjgl.PointerBuffer value) Unsafe version ofextra.
-