InteropUnityCUDA
InteropUnityCUDA copied to clipboard
Demonstrate interoperability between Unity Engine and CUDA
There are unit test for texture and compute buffer, but I need to implement it for texture array.
https://unity3d.atlassian.net/servicedesk/customer/portal/2/user/login?destination=portal%2F2%2FIN-25859
I wanted to generate the mip map of a `Texture2D` directly from the graphics API. But with DX11 a `Texture2D` is created with `miscflag 0`, and the function to generate...
CUDA is fast, but it's only supported by Nvidia's GPU. It would be better to use [HIP](https://developer.amd.com/resources/rocm-learning-center/fundamentals-of-hip-programming/) to support more GPU.
DirectX12 is not supported yet. The interoperability with CUDA doesn't work in the same way see https://forums.developer.nvidia.com/t/cuda-interop-with-d3d12-possible/54671/7
I tried packaging my own CUDA code into a DLL for Unity to call, but found that its performance was actually 10 times slower compared to calling it from an...