@@ -96,6 +96,7 @@ class SuperResolutionD3D12_DSR final : public SuperResolutionBase
9696 SuperResolutionD3D12_DSR (IReferenceCounters* pRefCounters,
9797 RenderDeviceD3D12Impl* pDevice,
9898 const SuperResolutionDesc& Desc,
99+ const SuperResolutionInfo& Info,
99100 IDSRDevice* pDSRDevice);
100101
101102 ~SuperResolutionD3D12_DSR ();
@@ -111,13 +112,13 @@ class SuperResolutionD3D12_DSR final : public SuperResolutionBase
111112SuperResolutionD3D12_DSR::SuperResolutionD3D12_DSR (IReferenceCounters* pRefCounters,
112113 RenderDeviceD3D12Impl* pDevice,
113114 const SuperResolutionDesc& Desc,
115+ const SuperResolutionInfo& Info,
114116 IDSRDevice* pDSRDevice) :
115- SuperResolutionBase{pRefCounters, Desc},
117+ SuperResolutionBase{pRefCounters, Desc, Info },
116118 m_pDevice{pDevice},
117119 m_DSRUpscalers (pDevice->GetCommandQueueCount ())
118120{
119121
120- ValidateTemporalSuperResolutionDesc (m_Desc);
121122 VERIFY_SUPER_RESOLUTION (m_Desc.Name , Desc.MotionFormat == TEX_FORMAT_RG16_FLOAT, " MotionFormat must be TEX_FORMAT_RG16_FLOAT. Got: " , GetTextureFormatAttribs (Desc.MotionFormat ).Name );
122123 VERIFY_SUPER_RESOLUTION (m_Desc.Name , (Desc.Flags & SUPER_RESOLUTION_FLAG_AUTO_EXPOSURE) != 0 || Desc.ExposureFormat != TEX_FORMAT_UNKNOWN,
123124 " ExposureFormat must not be TEX_FORMAT_UNKNOWN when SUPER_RESOLUTION_FLAG_AUTO_EXPOSURE is not set. "
@@ -169,7 +170,7 @@ SuperResolutionD3D12_DSR::~SuperResolutionD3D12_DSR() = default;
169170
170171void DILIGENT_CALL_TYPE SuperResolutionD3D12_DSR::Execute (const ExecuteSuperResolutionAttribs& Attribs)
171172{
172- ValidateTemporalExecuteSuperResolutionAttribs (m_Desc, Attribs);
173+ ValidateExecuteSuperResolutionAttribs (m_Desc, m_Info , Attribs);
173174 DEV_CHECK_SUPER_RESOLUTION (m_Desc.Name , Attribs.CameraNear > 0 , " CameraNear must be greater than zero for temporal upscaling" );
174175 DEV_CHECK_SUPER_RESOLUTION (m_Desc.Name , Attribs.CameraFar > 0 , " CameraFar must be greater than zero for temporal upscaling." );
175176 DEV_CHECK_SUPER_RESOLUTION (m_Desc.Name , Attribs.CameraFovAngleVert > 0 , " CameraFovAngleVert must be greater than zero for temporal upscaling." );
@@ -361,13 +362,14 @@ class DSRProviderD3D12 final : public SuperResolutionProvider
361362 }
362363
363364 virtual void CreateSuperResolution (const SuperResolutionDesc& Desc,
365+ const SuperResolutionInfo& Info,
364366 ISuperResolution** ppUpscaler) override final
365367 {
366368 DEV_CHECK_ERR (m_pDSRDevice != nullptr , " DirectSR device must not be null" );
367369 DEV_CHECK_ERR (m_pDevice != nullptr , " Render device must not be null" );
368370
369371 RenderDeviceD3D12Impl* pDeviceD3D12 = ClassPtrCast<RenderDeviceD3D12Impl>(m_pDevice.RawPtr ());
370- SuperResolutionD3D12_DSR* pUpscaler = NEW_RC_OBJ (GetRawAllocator (), " SuperResolutionD3D12_DSR instance" , SuperResolutionD3D12_DSR)(pDeviceD3D12, Desc, m_pDSRDevice);
372+ SuperResolutionD3D12_DSR* pUpscaler = NEW_RC_OBJ (GetRawAllocator (), " SuperResolutionD3D12_DSR instance" , SuperResolutionD3D12_DSR)(pDeviceD3D12, Desc, Info, m_pDSRDevice);
371373 pUpscaler->QueryInterface (IID_SuperResolution, reinterpret_cast <IObject**>(ppUpscaler));
372374 }
373375
0 commit comments