Hi, I have a problem. When i want to use a function of .cu file in CPP files like:
void postProcess_gpu(uint32_t* _SrcImg, uint32_t* _DstImg, int _rows, int _cols, int _kernal_size_x, int _kernal_size_y, CUstream _stream) {
dim3 block_size(32, 32);
int row_size = _rows % block_size.x == 0 ? _rows / block_size.x : (_rows / block_size.x + 1);
int col_size = _cols % block_size.y == 0 ? _cols / block_size.y : (_cols / block_size.y + 1);
dim3 thread_size(row_size, col_size);
postProcess_x << <block_size, thread_size, 0, _stream >> > (_SrcImg, _DstImg, _rows, _cols, _kernal_size_x);
postProcess_y << <block_size, thread_size, 0, _stream >> > (_SrcImg, _DstImg, _rows, _cols, _kernal_size_y);
//postProcess_mask << <block_size, thread_size, 0, _stream >> > (_SrcImg, _rows, _cols);
}
There is a error : Renderer.cpp.obj : error LNK2019: Inresolvable external symbols "void __cdecl postProcess_gpu (…)
But my .CU file has already generated a .OBJ file with the new setting CUDA_SOURCE_PROPERTY_FORMAT in CMAKE, so I don’t know why I can’t find this function?