summaryrefslogtreecommitdiffstats
path: root/tools/gfx/d3d12/d3d12-buffer.cpp
diff options
context:
space:
mode:
authorEllie Hermaszewska <ellieh@nvidia.com>2023-04-29 11:32:53 +0800
committerGitHub <noreply@github.com>2023-04-29 11:32:53 +0800
commit5adecbe837d27cf4e0a554ae13a0338743a8cb4b (patch)
treec1e791427a2b57165f950f5df264bbaca551ccaf /tools/gfx/d3d12/d3d12-buffer.cpp
parent5df7ada451a993efff2b80bb1af2d8c7579ba00b (diff)
vkd3d and dxvk integration (#2823)
* Add d3d sources for linux builds * Return NOT_IMPLEMENTED for shared handle support on Linux * Enable DirectX api on Linux * Do not report DX11 support without FXC * Initial version of SynchAPI emulation * Neaten dx library name handling * Neaten and use posix-synchapi * Add premake option for DirectX on Vulkan * s/SLANG_ENABLE_VKD3D_PROTON/SLANG_ENABLE_VKD3D * Skip failing tests on vkd3d * Regenerate vs projects * Silence unused var warning
Diffstat (limited to 'tools/gfx/d3d12/d3d12-buffer.cpp')
-rw-r--r--tools/gfx/d3d12/d3d12-buffer.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/tools/gfx/d3d12/d3d12-buffer.cpp b/tools/gfx/d3d12/d3d12-buffer.cpp
index 42babfae6..7d3376607 100644
--- a/tools/gfx/d3d12/d3d12-buffer.cpp
+++ b/tools/gfx/d3d12/d3d12-buffer.cpp
@@ -35,6 +35,9 @@ Result BufferResourceImpl::getNativeResourceHandle(InteropHandle* outHandle)
Result BufferResourceImpl::getSharedHandle(InteropHandle* outHandle)
{
+#if !SLANG_WINDOWS_FAMILY
+ return SLANG_E_NOT_IMPLEMENTED;
+#else
// Check if a shared handle already exists for this resource.
if (sharedHandle.handleValue != 0)
{
@@ -51,6 +54,7 @@ Result BufferResourceImpl::getSharedHandle(InteropHandle* outHandle)
outHandle->api = InteropHandleAPI::D3D12;
sharedHandle = *outHandle;
return SLANG_OK;
+#endif
}
Result BufferResourceImpl::map(MemoryRange* rangeToRead, void** outPointer)