clEnqueueCopyBuffer
clEnqueueCopyBuffer is an OpenCL API function that enqueues a command to copy a block of memory from one buffer to another within a specified command queue. The copy operates on device memory and is performed asynchronously relative to the host, allowing overlap with host work.
Signature: cl_int clEnqueueCopyBuffer(cl_command_queue command_queue, cl_mem src_buffer, cl_mem dst_buffer, size_t src_offset, size_t dst_offset, size_t cb, cl_uint num_events_in_wait_list,
Parameters: command_queue must be a valid command queue associated with a context. src_buffer and dst_buffer must
Notes: The copy is constrained by the sizes of the source and destination buffers; src_offset + cb
Return values: On success, CL_SUCCESS is returned. Error codes may include CL_INVALID_COMMAND_QUEUE, CL_INVALID_MEM_OBJECT, CL_INVALID_VALUE, and CL_INVALID_EVENT_WAIT_LIST,
See also: clEnqueueReadBuffer, clEnqueueWriteBuffer, clEnqueueCopyBufferRect.