What is the difference between slang-gfx and slang-rhi #6802
-
Just come across the the build rhi option in the build instructions and then the repo for it. Is this meant to be a replacement to gfx or a higher level implementation or something like that? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
My understanding is the RHI stands for Render Hardware Interface and it is an abstract interface that works for all render APIs such as Vulkan , Metal, WGPU and D3D. Slang-gfx is the implementation for each render API. So they are not replacement. One is an interface set and another is the implementation. |
Beta Was this translation helpful? Give feedback.
-
slang-gfx is a legacy graphics abstraction layer, it's originally only for Vulkan and D3D. Since we want to support more target graphics API such Metal, WebGPU, and more complex reflections usage in the abstraction layer, we noticed that the slang-gfx doesn't do very good job on abstracting those graphics APIs (e.g. some resource types on Metal doesn't exist at all at slang-gfx). So we re-design the layer and hope to make it more general to cover all existing graphics APIs, and that is slang-rhi. |
Beta Was this translation helpful? Give feedback.
slang-gfx is a legacy graphics abstraction layer, it's originally only for Vulkan and D3D.
Since we want to support more target graphics API such Metal, WebGPU, and more complex reflections usage in the abstraction layer, we noticed that the slang-gfx doesn't do very good job on abstracting those graphics APIs (e.g. some resource types on Metal doesn't exist at all at slang-gfx). So we re-design the layer and hope to make it more general to cover all existing graphics APIs, and that is slang-rhi.