|
I've been looking through the renderer backends and noticed that every backend exposes a working implementation of OpenGL, D3D11, D3D12, Metal, WebGPU, all return their native texture handle in some form. Looking through the vulkan renderer, I was wondering why this couldn't simply be something like this I have a basic understanding of vulkan resource management, synchronization, image layouts, ownership, and command queues, but I don't immediately see what fundamental issue would prevent exposing the underlying The reason I'm asking is that I'm currently working on integrating BGFX with DLSS on supported backends. I already have it working on D3D12 using I don't have any problem maintaining a fork and adding something like the implementation above for my own use. What I'm really interested in is understanding why the vulkan backend intentionally doesn't expose the native handle. |
Replies: 1 comment
|
Better integration if you want to mess with textures is |
bgfx::getInternalandbgfx::overrideInternalare hacky APIs that don't work everywhere.Better integration if you want to mess with textures is
bgfx::createTexture2Dby passing_external, which is texture you created with underlying API.https://bkaradzic.github.io/bgfx/bgfx.html#_CPPv4N4bgfx15createTexture2DE8uint16_t8uint16_tb8uint16_tN13TextureFormat4EnumE8uint64_tPK6Memory8uint64_t