diff options
| author | Yong He <yonghe@outlook.com> | 2021-03-24 13:57:55 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-03-24 13:57:55 -0700 |
| commit | 98afb421f408aa8651afff3dba1b21fad71131fe (patch) | |
| tree | a8610d12ac7d74a8772cb6ecdd810da8216baa67 /build | |
| parent | d0f7b7f0ed1d0d1388ce944cd1ad906bbd9afb35 (diff) | |
Reimplement Vulkan shader objects. (#1764)
* Reimplement Vulkan shader objects.
This change reimplements Vulkan shader objects in the `gfx` layer so that it is no longer layered on top of the `DescriptorSet` abstraction. Since this is the last implementation that uses `DescriptorSet`, the change also removes all `DescriptorSet` related API from public `gfx` interface.
The Vulkan implementation now passes all test cases, but it still have two issues:
1. The PushConstant setting is not correct, this is because we don't seem to be able to get correct reflection data about the size of push constants for an entry-point.
2. The `shader-toy` example can't run on Vulkan, because it currently sets nullptr to `Texture` bindings, and this change doesn't properly handle setting resource to null in `ShaderObject`s yet. If we can use the `nullDescriptor` feature on vulkan, this implementation will be simple. However we still want to decide whether we want to use a Vulkan 1.2 feature for this.
* Fix up
Diffstat (limited to 'build')
| -rw-r--r-- | build/visual-studio/core/core.vcxproj | 1 | ||||
| -rw-r--r-- | build/visual-studio/core/core.vcxproj.filters | 3 | ||||
| -rw-r--r-- | build/visual-studio/gfx/gfx.vcxproj | 2 | ||||
| -rw-r--r-- | build/visual-studio/gfx/gfx.vcxproj.filters | 6 |
4 files changed, 4 insertions, 8 deletions
diff --git a/build/visual-studio/core/core.vcxproj b/build/visual-studio/core/core.vcxproj index 38bcf2ade..2f48f93eb 100644 --- a/build/visual-studio/core/core.vcxproj +++ b/build/visual-studio/core/core.vcxproj @@ -178,6 +178,7 @@ <ClInclude Include="..\..\..\source\core\slang-blob.h" /> <ClInclude Include="..\..\..\source\core\slang-byte-encode-util.h" /> <ClInclude Include="..\..\..\source\core\slang-char-util.h" /> + <ClInclude Include="..\..\..\source\core\slang-chunked-list.h" /> <ClInclude Include="..\..\..\source\core\slang-common.h" /> <ClInclude Include="..\..\..\source\core\slang-compression-system.h" /> <ClInclude Include="..\..\..\source\core\slang-deflate-compression-system.h" /> diff --git a/build/visual-studio/core/core.vcxproj.filters b/build/visual-studio/core/core.vcxproj.filters index 9c718a6fb..5e63e4681 100644 --- a/build/visual-studio/core/core.vcxproj.filters +++ b/build/visual-studio/core/core.vcxproj.filters @@ -33,6 +33,9 @@ <ClInclude Include="..\..\..\source\core\slang-char-util.h"> <Filter>Header Files</Filter> </ClInclude> + <ClInclude Include="..\..\..\source\core\slang-chunked-list.h"> + <Filter>Header Files</Filter> + </ClInclude> <ClInclude Include="..\..\..\source\core\slang-common.h"> <Filter>Header Files</Filter> </ClInclude> diff --git a/build/visual-studio/gfx/gfx.vcxproj b/build/visual-studio/gfx/gfx.vcxproj index 08786b5cf..01faf88bd 100644 --- a/build/visual-studio/gfx/gfx.vcxproj +++ b/build/visual-studio/gfx/gfx.vcxproj @@ -195,7 +195,6 @@ <ClInclude Include="..\..\..\tools\gfx\nvapi\nvapi-include.h" /> <ClInclude Include="..\..\..\tools\gfx\nvapi\nvapi-util.h" /> <ClInclude Include="..\..\..\tools\gfx\open-gl\render-gl.h" /> - <ClInclude Include="..\..\..\tools\gfx\render-graphics-common.h" /> <ClInclude Include="..\..\..\tools\gfx\renderer-shared.h" /> <ClInclude Include="..\..\..\tools\gfx\simple-render-pass-layout.h" /> <ClInclude Include="..\..\..\tools\gfx\slang-context.h" /> @@ -220,7 +219,6 @@ <ClCompile Include="..\..\..\tools\gfx\immediate-renderer-base.cpp" /> <ClCompile Include="..\..\..\tools\gfx\nvapi\nvapi-util.cpp" /> <ClCompile Include="..\..\..\tools\gfx\open-gl\render-gl.cpp" /> - <ClCompile Include="..\..\..\tools\gfx\render-graphics-common.cpp" /> <ClCompile Include="..\..\..\tools\gfx\render.cpp" /> <ClCompile Include="..\..\..\tools\gfx\renderer-shared.cpp" /> <ClCompile Include="..\..\..\tools\gfx\simple-render-pass-layout.cpp" /> diff --git a/build/visual-studio/gfx/gfx.vcxproj.filters b/build/visual-studio/gfx/gfx.vcxproj.filters index cff8cc95a..99af1fbbd 100644 --- a/build/visual-studio/gfx/gfx.vcxproj.filters +++ b/build/visual-studio/gfx/gfx.vcxproj.filters @@ -57,9 +57,6 @@ <ClInclude Include="..\..\..\tools\gfx\open-gl\render-gl.h"> <Filter>Header Files</Filter> </ClInclude> - <ClInclude Include="..\..\..\tools\gfx\render-graphics-common.h"> - <Filter>Header Files</Filter> - </ClInclude> <ClInclude Include="..\..\..\tools\gfx\renderer-shared.h"> <Filter>Header Files</Filter> </ClInclude> @@ -128,9 +125,6 @@ <ClCompile Include="..\..\..\tools\gfx\open-gl\render-gl.cpp"> <Filter>Source Files</Filter> </ClCompile> - <ClCompile Include="..\..\..\tools\gfx\render-graphics-common.cpp"> - <Filter>Source Files</Filter> - </ClCompile> <ClCompile Include="..\..\..\tools\gfx\render.cpp"> <Filter>Source Files</Filter> </ClCompile> |
