[D3D12] Don't assume there's a null D3D descriptor handle

This commit is contained in:
Triang3l
2019-11-04 21:10:32 +03:00
parent c499229455
commit 00116fad2d
2 changed files with 17 additions and 6 deletions

View File

@@ -363,7 +363,10 @@ class TextureCache {
// SRV descriptor from the cache, for the first swizzle the texture was used
// with (which is usually determined by the format, such as RGBA or BGRA).
// If swizzle is kCachedSRVDescriptorSwizzleMissing, the cached descriptor
// doesn't exist yet (there are no invalid D3D descriptor handle values).
D3D12_CPU_DESCRIPTOR_HANDLE cached_srv_descriptor;
static constexpr uint32_t kCachedSRVDescriptorSwizzleMissing = UINT32_MAX;
uint32_t cached_srv_descriptor_swizzle;
// Watch handles for the memory ranges (protected by the shared memory watch