Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

I don't have a lot of experience with OpenCV CUDA functionality, so I'm not sure about the problem from the details given. However, one thing to check would be that your build of OpenCV is configured for CUDA. I think (though could be wrong) that the builds provided on the OpenCV site site aren't configured to use CUDA by default. The details are here:

I think there's a WITH_CUDA flag that needs to be set for the build, and you need to have the CUDA toolkit installed before you build. If you don't have it installed, OpenCV still builds, but just doesn't work (helpful right?).

Try calling the function gpu::getCudaEnabledDeviceCount(). If you have a CUDA-enabled device available and OpenCV is built for CUDA, it should return a positive number. If it returns 0, and you definitely have a CUDA device available, then my guess is it's a build issue.