nanovdb::CudaDeviceBuffer
nanovdb::HostBuffer
Otherwise, here's some more details :
I'm following this example : https://github.com/AcademySoftwareFoundation/openvdb/tree/master/nanovdb/nanovdb/examples/ex_openvdb_to_nanovdb_cuda [github.com]
There's my code to first convert a regular GridCPtr to a const openvdb::FloatGrid then to a NanoVDB grid :
const auto densityFloatGrid = openvdb::gridConstPtrCast<openvdb::FloatGrid>(density); // Converts the OpenVDB to NanoVDB and returns a GridHandle that uses CUDA for memory management. auto handle = nanovdb::createNanoGrid<openvdb::FloatGrid, float, nanovdb::CudaDeviceBuffer>(*densityFloatGrid);
Where this line to convert throws this linking error :
error LNK2019: unresolved external symbol "public: __cdecl nanovdb::GridHandle<class nanovdb::CudaDeviceBuffer>::GridHandle<class nanovdb::CudaDeviceBuffer><class nanovdb::CudaDeviceBuffer,0>(class nanovdb::CudaDeviceBuffer &&)" (??$?0VCudaDeviceBuffer@nanovdb@@$0A@@?$GridHandle@VCudaDeviceBuffer@nanovdb@@@nanovdb@@QEAA@$$QEAVCudaDeviceBuffer@1@@Z) referenced in function "private: class nanovdb::GridHandle<class nanovdb::CudaDeviceBuffer> __cdecl nanovdb::CreateNanoGrid<class openvdb::v11_0_sesi::Grid<class openvdb::v11_0_sesi::tree::Tree<class openvdb::v11_0_sesi::tree::RootNode<class openvdb::v11_0_sesi::tree::InternalNode<class openvdb::v11_0_sesi::tree::InternalNode<class openvdb::v11_0_sesi::tree::LeafNode<float,3>,4>,5> > > > >::initHandle<float,class nanovdb::CudaDeviceBuffer>(class nanovdb::CudaDeviceBuffer const &)" (??$initHandle@MVCudaDeviceBuffer@nanovdb@@@?$CreateNanoGrid@V?$Grid@V?$Tree@V?$RootNode@V?$InternalNode@V?$InternalNode@V?$LeafNode@M$02@tree@v11_0_sesi@openvdb@@$03@tree@v11_0_sesi@openvdb@@$04@tree@v11_0_sesi@openvdb@@@tree@v11_0_sesi@openvdb@@@tree@v11_0_sesi@openvdb@@@v11_0_sesi@openvdb@@@nanovdb@@AEAA?AV?$GridHandle@VCudaDeviceBuffer@nanovdb@@@1@AEBVCudaDeviceBuffer@1@@Z)
I tried linking with every Cuda & Houdini Lib without success. I hope someone can help !
Thanks