diff --git a/src/transient-resource-heap-base.h b/src/transient-resource-heap-base.h index e48ced97..8cbadb4e 100644 --- a/src/transient-resource-heap-base.h +++ b/src/transient-resource-heap-base.h @@ -141,7 +141,7 @@ class TransientResourceHeapBaseImpl : public TransientResourceHeap m_constantBufferPool.init( device, - MemoryType::Upload, + MemoryType::DeviceLocal, 256, BufferUsage::ConstantBuffer | BufferUsage::CopySource | BufferUsage::CopyDestination ); diff --git a/src/wgpu/wgpu-device.cpp b/src/wgpu/wgpu-device.cpp index 42c09b6e..2fc6c519 100644 --- a/src/wgpu/wgpu-device.cpp +++ b/src/wgpu/wgpu-device.cpp @@ -33,7 +33,11 @@ Context::~Context() } } -DeviceImpl::~DeviceImpl() {} +DeviceImpl::~DeviceImpl() +{ + m_shaderObjectLayoutCache = decltype(m_shaderObjectLayoutCache)(); + m_queue.setNull(); +} Result DeviceImpl::getNativeDeviceHandles(DeviceNativeHandles* outHandles) {