Function rcudnn_sys::cudaMemcpy2DFromArray[][src]

pub unsafe extern "C" fn cudaMemcpy2DFromArray(
    dst: *mut c_void,
    dpitch: usize,
    src: cudaArray_const_t,
    wOffset: usize,
    hOffset: usize,
    width: usize,
    height: usize,
    kind: cudaMemcpyKind
) -> cudaError_t
Expand description

\brief Copies data between host and device

Copies a matrix (\p height rows of \p width bytes each) from the CUDA array \p src starting at \p hOffset rows and \p wOffset bytes from the upper left corner to the memory area pointed to by \p dst, where \p kind specifies the direction of the copy, and must be one of ::cudaMemcpyHostToHost, ::cudaMemcpyHostToDevice, ::cudaMemcpyDeviceToHost, ::cudaMemcpyDeviceToDevice, or ::cudaMemcpyDefault. Passing ::cudaMemcpyDefault is recommended, in which case the type of transfer is inferred from the pointer values. However, ::cudaMemcpyDefault is only allowed on systems that support unified virtual addressing. \p dpitch is the width in memory in bytes of the 2D array pointed to by \p dst, including any padding added to the end of each row. \p wOffset + \p width must not exceed the width of the CUDA array \p src. \p width must not exceed \p dpitch. ::cudaMemcpy2DFromArray() returns an error if \p dpitch exceeds the maximum allowed.

\param dst - Destination memory address \param dpitch - Pitch of destination memory \param src - Source memory address \param wOffset - Source starting X offset (columns in bytes) \param hOffset - Source starting Y offset (rows) \param width - Width of matrix transfer (columns in bytes) \param height - Height of matrix transfer (rows) \param kind - Type of transfer

\return ::cudaSuccess, ::cudaErrorInvalidValue, ::cudaErrorInvalidPitchValue, ::cudaErrorInvalidMemcpyDirection \notefnerr \note_sync \note_init_rt \note_callback \note_memcpy

\sa ::cudaMemcpy, ::cudaMemcpy2D, ::cudaMemcpy2DToArray, ::cudaMemcpy2DArrayToArray, ::cudaMemcpyToSymbol, ::cudaMemcpyFromSymbol, ::cudaMemcpyAsync, ::cudaMemcpy2DAsync, ::cudaMemcpy2DToArrayAsync, ::cudaMemcpy2DFromArrayAsync, ::cudaMemcpyToSymbolAsync, ::cudaMemcpyFromSymbolAsync, ::cuMemcpy2D, ::cuMemcpy2DUnaligned