Calling CUDA-accelerated Libraries from MATLAB: A Computer Vision Example

Originally published at:

In an earlier post we showed how MATLAB® can support CUDA kernel prototyping and development by providing an environment for quick evaluation and visualization using the CUDAKernel object. In this post I will show you how to integrate an existing library of both host and device code implemented in C++ or another CUDA-accelerated language using MEX.…

Note that with the recent release of MATLAB R2015b comes a new tool called MEXCUDA. This function displaces the use of MEX for CUDA code and eliminates the need to copy an options file or specify 'largeArrayDims'. See the documentation: