Modifier and Type | Method and Description |
---|---|
static Pointer |
CL.clSVMAlloc(cl_context context,
long flags,
long size,
int alignment)
Allocates a shared virtual memory (SVM) buffer that can be shared by the host and all devices in an OpenCL context that support shared virtual memory.
|
static Pointer |
Pointer.to(java.nio.Buffer buffer)
NOTE: This method does not take into account the position
and array offset of the given buffer.
|
static Pointer |
Pointer.to(byte[] values)
Creates a new Pointer to the given values.
|
static Pointer |
Pointer.to(char[] values)
Creates a new Pointer to the given values.
|
static Pointer |
Pointer.to(double[] values)
Creates a new Pointer to the given values.
|
static Pointer |
Pointer.to(float[] values)
Creates a new Pointer to the given values.
|
static Pointer |
Pointer.to(int[] values)
Creates a new Pointer to the given values.
|
static Pointer |
Pointer.to(long[] values)
Creates a new Pointer to the given values.
|
static Pointer |
Pointer.to(NativePointerObject... pointers)
Creates a new Pointer to the given Pointers.
|
static Pointer |
Pointer.to(NativePointerObject pointer)
Creates a new Pointer to the given Pointer.
|
static Pointer |
Pointer.to(short[] values)
Creates a new Pointer to the given values.
|
static Pointer |
Pointer.toBuffer(java.nio.Buffer buffer)
Creates a new Pointer to the given buffer.
|
Pointer |
Pointer.withByteOffset(long byteOffset)
Returns a new pointer with an offset of the given number
of bytes
|
Modifier and Type | Method and Description |
---|---|
static cl_mem |
CL.clCreateBuffer(cl_context context,
long flags,
long size,
Pointer host_ptr,
int[] errcode_ret)
Creates a buffer object.
|
static cl_mem |
CL.clCreateImage(cl_context context,
long flags,
cl_image_format image_format,
cl_image_desc image_desc,
Pointer host_ptr,
int[] errcode_ret)
Creates a 1D image, 1D image buffer, 1D image array, 2D image, 2D image array or 3D image object.
|
static cl_mem |
CL.clCreateImage2D(cl_context context,
long flags,
cl_image_format[] image_format,
long image_width,
long image_height,
long image_row_pitch,
Pointer host_ptr,
int[] errcode_ret)
Deprecated.
As of OpenCL 1.2 and replaced by
CL.clCreateImage(cl_context, long, cl_image_format, cl_image_desc, Pointer, int[]) |
static cl_mem |
CL.clCreateImage3D(cl_context context,
long flags,
cl_image_format[] image_format,
long image_width,
long image_height,
long image_depth,
long image_row_pitch,
long image_slice_pitch,
Pointer host_ptr,
int[] errcode_ret)
Deprecated.
As of OpenCL 1.2 and replaced by
CL.clCreateImage(cl_context, long, cl_image_format, cl_image_desc, Pointer, int[]) |
static cl_mem |
CL.clCreateSubBuffer(cl_mem buffer,
long flags,
int buffer_create_type,
Pointer buffer_create_info,
int[] errcode_ret)
Deprecated.
The buffer_create_info that has to be passed to this function
is specific for the underlying architecture (32/64 bit). The preferred
way of creating a sub-buffer is now via
CL.clCreateSubBuffer(cl_mem, long, int, cl_buffer_region, int[]) |
static int |
CL.clEnqueueFillBuffer(cl_command_queue command_queue,
cl_mem buffer,
Pointer pattern,
long pattern_size,
long offset,
long size,
int num_events_in_wait_list,
cl_event[] event_wait_list,
cl_event event)
Enqueues a command to fill a buffer object with a pattern of a given pattern size.
|
static int |
CL.clEnqueueFillImage(cl_command_queue command_queue,
cl_mem image,
Pointer fill_color,
long[] origin,
long[] region,
int num_events_in_wait_list,
cl_event[] event_wait_list,
cl_event event)
Enqueues a command to fill an image object with a specified color.
|
static int |
CL.clEnqueueNativeKernel(cl_command_queue command_queue,
EnqueueNativeKernelFunction user_func,
java.lang.Object args,
long cb_args,
int num_mem_objects,
cl_mem[] mem_list,
Pointer[] args_mem_loc,
int num_events_in_wait_list,
cl_event[] event_wait_list,
cl_event event)
Enqueues a command to execute a native C/C++ function not compiled using the OpenCL compiler.
|
static int |
CL.clEnqueueReadBuffer(cl_command_queue command_queue,
cl_mem buffer,
boolean blocking_read,
long offset,
long cb,
Pointer ptr,
int num_events_in_wait_list,
cl_event[] event_wait_list,
cl_event event)
Enqueue commands to read from a buffer object to host memory.
|
static int |
CL.clEnqueueReadBufferRect(cl_command_queue command_queue,
cl_mem buffer,
boolean blocking_read,
long[] buffer_offset,
long[] host_offset,
long[] region,
long buffer_row_pitch,
long buffer_slice_pitch,
long host_row_pitch,
long host_slice_pitch,
Pointer ptr,
int num_events_in_wait_list,
cl_event[] event_wait_list,
cl_event event)
Enqueue commands to read from a rectangular region from a buffer object to host memory.
|
static int |
CL.clEnqueueReadImage(cl_command_queue command_queue,
cl_mem image,
boolean blocking_read,
long[] origin,
long[] region,
long row_pitch,
long slice_pitch,
Pointer ptr,
int num_events_in_wait_list,
cl_event[] event_wait_list,
cl_event event)
Enqueues a command to read from a 2D or 3D image object to host memory.
|
static int |
CL.clEnqueueSVMFree(cl_command_queue command_queue,
int num_svm_pointers,
Pointer[] svm_pointers,
SVMFreeFunction pfn_free_func,
java.lang.Object user_data,
int num_events_in_wait_list,
cl_event[] event_wait_list,
cl_event event)
Enqueues a command to free the shared virtual memory allocated using clSVMAlloc or a shared system memory pointer.
|
static int |
CL.clEnqueueSVMMap(cl_command_queue command_queue,
boolean blocking_map,
long flags,
Pointer svm_ptr,
long size,
int num_events_in_wait_list,
cl_event[] event_wait_list,
cl_event event)
Enqueues a command that will allow the host to update a region of a SVM buffer.
|
static int |
CL.clEnqueueSVMMemcpy(cl_command_queue command_queue,
boolean blocking_copy,
Pointer dst_ptr,
Pointer src_ptr,
long size,
int num_events_in_wait_list,
cl_event[] event_wait_list,
cl_event event)
Enqueues a command to do a memcpy operation.
|
static int |
CL.clEnqueueSVMMemFill(cl_command_queue command_queue,
Pointer svm_ptr,
Pointer pattern,
long pattern_size,
long size,
int num_events_in_wait_list,
cl_event[] event_wait_list,
cl_event event)
Enqueues a command to fill a region in memory with a pattern of a given pattern size.
|
static int |
CL.clEnqueueSVMUnmap(cl_command_queue command_queue,
Pointer svm_ptr,
int num_events_in_wait_list,
cl_event[] event_wait_list,
cl_event event)
Enqueues a command to indicate that the host has completed
updating the region given by
svm_ptr and which was specified in a
previous call to clEnqueueSVMMap. |
static int |
CL.clEnqueueWriteBuffer(cl_command_queue command_queue,
cl_mem buffer,
boolean blocking_write,
long offset,
long cb,
Pointer ptr,
int num_events_in_wait_list,
cl_event[] event_wait_list,
cl_event event)
Enqueue commands to write to a buffer object from host memory.
|
static int |
CL.clEnqueueWriteBufferRect(cl_command_queue command_queue,
cl_mem buffer,
boolean blocking_write,
long[] buffer_offset,
long[] host_offset,
long[] region,
long buffer_row_pitch,
long buffer_slice_pitch,
long host_row_pitch,
long host_slice_pitch,
Pointer ptr,
int num_events_in_wait_list,
cl_event[] event_wait_list,
cl_event event)
Enqueue commands to write a rectangular region to a buffer object from host memory.
|
static int |
CL.clEnqueueWriteImage(cl_command_queue command_queue,
cl_mem image,
boolean blocking_write,
long[] origin,
long[] region,
long input_row_pitch,
long input_slice_pitch,
Pointer ptr,
int num_events_in_wait_list,
cl_event[] event_wait_list,
cl_event event)
Enqueues a command to write to a 2D or 3D image object from host memory.
|
static int |
CL.clGetCommandQueueInfo(cl_command_queue command_queue,
int param_name,
long param_value_size,
Pointer param_value,
long[] param_value_size_ret)
Query information about a command-queue.
|
static int |
CL.clGetContextInfo(cl_context context,
int param_name,
long param_value_size,
Pointer param_value,
long[] param_value_size_ret)
Query information about a context.
|
static int |
CL.clGetDeviceInfo(cl_device_id device,
int param_name,
long param_value_size,
Pointer param_value,
long[] param_value_size_ret)
Get information about an OpenCL device.
|
static int |
CL.clGetEventInfo(cl_event event,
int param_name,
long param_value_size,
Pointer param_value,
long[] param_value_size_ret)
Returns information about the event object.
|
static int |
CL.clGetEventProfilingInfo(cl_event event,
int param_name,
long param_value_size,
Pointer param_value,
long[] param_value_size_ret)
Returns profiling information for the command associated with event if profiling is enabled.
|
static int |
CL.clGetGLTextureInfo(cl_mem memobj,
int param_name,
long param_value_size,
Pointer param_value,
long[] param_value_size_ret)
Returns additional information about the GL texture object associated with a memory object.
|
static int |
CL.clGetImageInfo(cl_mem image,
int param_name,
long param_value_size,
Pointer param_value,
long[] param_value_size_ret)
Get information specific to an image object.
|
static int |
CL.clGetKernelArgInfo(cl_kernel kernel,
int arg_indx,
int param_name,
long param_value_size,
Pointer param_value,
long[] param_value_size_ret)
Returns information about the arguments of a kernel.
|
static int |
CL.clGetKernelInfo(cl_kernel kernel,
int param_name,
long param_value_size,
Pointer param_value,
long[] param_value_size_ret)
Returns information about the kernel object.
|
static int |
CL.clGetKernelWorkGroupInfo(cl_kernel kernel,
cl_device_id device,
int param_name,
long param_value_size,
Pointer param_value,
long[] param_value_size_ret)
Returns information about the kernel object that may be specific to a device.
|
static int |
CL.clGetMemObjectInfo(cl_mem memobj,
int param_name,
long param_value_size,
Pointer param_value,
long[] param_value_size_ret)
Used to get information that is common to all memory objects (buffer and image objects).
|
static int |
CL.clGetPipeInfo(cl_mem pipe,
int param_name,
long param_value_size,
Pointer param_value,
long[] param_value_size_ret)
Get information specific to a pipe object created with clCreatePipe.
|
static int |
CL.clGetPlatformInfo(cl_platform_id platform,
int param_name,
long param_value_size,
Pointer param_value,
long[] param_value_size_ret)
Get specific information about the OpenCL platform.
|
static int |
CL.clGetProgramBuildInfo(cl_program program,
cl_device_id device,
int param_name,
long param_value_size,
Pointer param_value,
long[] param_value_size_ret)
Returns build information for each device in the program object.
|
static int |
CL.clGetProgramInfo(cl_program program,
int param_name,
long param_value_size,
Pointer param_value,
long[] param_value_size_ret)
Returns information about the program object.
|
static int |
CL.clGetSamplerInfo(cl_sampler sampler,
int param_name,
long param_value_size,
Pointer param_value,
long[] param_value_size_ret)
Returns information about the sampler object.
|
static int |
CL.clSetKernelArg(cl_kernel kernel,
int arg_index,
long arg_size,
Pointer arg_value)
Used to set the argument value for a specific argument of a kernel.
|
static int |
CL.clSetKernelArgSVMPointer(cl_kernel kernel,
int arg_index,
Pointer arg_value)
Used to set a SVM pointer as the argument value for a specific argument of a kernel.
|
static int |
CL.clSetKernelExecInfo(cl_kernel kernel,
int param_name,
long param_value_size,
Pointer param_value)
Used to pass additional information other than argument values to a kernel.
|
static void |
CL.clSVMFree(cl_context context,
Pointer svm_pointer)
Frees a shared virtual memory buffer allocated using clSVMAlloc.
|
void |
SVMFreeFunction.function(cl_command_queue queue,
int num_svm_pointers,
Pointer[] svm_pointers,
java.lang.Object user_data)
The function that will be called
|
void |
CreateContextFunction.function(java.lang.String errinfo,
Pointer private_info,
long cb,
java.lang.Object user_data)
The function that will be called.
|
Constructor and Description |
---|
Pointer(Pointer other)
Copy constructor
|
Pointer(Pointer other,
long byteOffset)
Creates a copy of the given pointer, with an
additional byte offset
|