I have a running OpTiX (v. 3.0.0) project running on MS Visual Studio Ultimate 2012 and I want to post process some data using C CUDA kernels (v. 5.5).
I can not find information on how to reconfigure the original OpTiX project such that it recognizes and launches the CUDA kernels. The ocean sample in the OptIX SDK does not seem to help since it uses the CuFFT library.
In particular I want to add the following example code in my project:
/***************/
// CUDA runtime
#include <cuda_runtime.h>
// test for CUDA within holorenderer
global void propagate_kernel(float *OPL_L) {
return;
}
host void propagate (float OPL_L) {
// launch the kernel
propagate_kernel<<<128,512>>>(OPL_L);
}
/**************/
If I add it as a .c file MSVS returns the following compile time error:
error C2059: syntax error : ‘<’ propagation.c
which indicates that the C compiler does not recognize the CUDA kernel launch operator
If I add it as a .cu file MSVS returns the following linker error:
error LNK2019: unresolved external symbol _propagate referenced in function …
which seems to indicate that the resulting file is not being linked in . This is expected since OpTiX loads the ptx files in runtime…
Any example on how to configure this project?
I saw in stackoverflow.com a reference to a similar question in:
but I do not manage to access this link.