I have written an application in C++ that makes heavy use of basic openCV functions along with basic C. It works as desired on the Jetson Nano, but it executes too slowly. I would like to modify some of my functions to make use of CUDA where possible. I found a nice intro to CUDA tutorial that I used for reference to make a simple, small version of my application to get started.
So far the compile step seems to work, but I get “undefined reference” errors from the linker for several openCV function calls in the .cu file. The tutorial has only a single code file with just 2 #includes (iostream & math.h). Is there another example that shows how to use CUDA and openCV functions within a single file named with the .cu extension? I am calling nvcc to compile and link all in one step, and I use option -I to tell nvcc where opencv is located.