Diligent Engine
 
Loading...
Searching...
No Matches
Diligent::ISuperResolutionFactory Struct Referenceabstract

#include <SuperResolutionFactory.h>

Inheritance diagram for Diligent::ISuperResolutionFactory:
Diligent.IObject

Public Member Functions

virtual void DILIGENT_CALL_TYPE EnumerateVariants (Uint32 &NumVariants, SuperResolutionInfo *Variants)=0
 Enumerates the supported super resolution variants.
 
virtual void DILIGENT_CALL_TYPE GetSourceSettings (const SuperResolutionSourceSettingsAttribs &Attribs, SuperResolutionSourceSettings &Settings) const =0
 Returns the optimal source (input) settings for super resolution upscaling.
 
virtual void DILIGENT_CALL_TYPE CreateSuperResolution (const SuperResolutionDesc &Desc, ISuperResolution **ppUpscaler)=0
 Creates a new upscaler object.
 
virtual void DILIGENT_CALL_TYPE SetMessageCallback (DebugMessageCallbackType MessageCallback) const =0
 Sets a user-provided debug message callback.
 
virtual void DILIGENT_CALL_TYPE SetBreakOnError (bool BreakOnError) const =0
 Sets whether to break program execution on assertion failure.
 
virtual void DILIGENT_CALL_TYPE SetMemoryAllocator (IMemoryAllocator *pAllocator) const =0
 Sets the memory allocator to be used by the SuperResolution.
 
- Public Member Functions inherited from Diligent.IObject
virtual void DILIGENT_CALL_TYPE QueryInterface (const INTERFACE_ID &IID, IObject **ppInterface)=0
 Queries the specific interface.
 
template<typename DerivedType, typename = typename std::enable_if<std::is_base_of<IObject, DerivedType>::value>::type>
void QueryInterface (const INTERFACE_ID &IID, DerivedType **ppInterface)
 
virtual ReferenceCounterValueType DILIGENT_CALL_TYPE AddRef ()=0
 Increments the number of strong references by 1.
 
virtual ReferenceCounterValueType DILIGENT_CALL_TYPE Release ()=0
 
virtual IReferenceCounters *DILIGENT_CALL_TYPE GetReferenceCounters () const =0
 

Detailed Description

SuperResolution factory interface

The factory is created per render device using CreateSuperResolutionFactory(). It enumerates available super resolution backends, queries optimal settings, and creates upscaler instances for the device it was created with.

Member Function Documentation

◆ CreateSuperResolution()

virtual void DILIGENT_CALL_TYPE Diligent::ISuperResolutionFactory::CreateSuperResolution ( const SuperResolutionDesc & Desc,
ISuperResolution ** ppUpscaler )
pure virtual

Creates a new upscaler object.

Parameters
[in]Desc- Super resolution upscaler description, see Diligent::SuperResolutionDesc for details.
[out]ppUpscaler- Address of the memory location where a pointer to the super resolution upscaler interface will be written. The function calls AddRef(), so that the new object will have one reference.
Remarks
On backends that don't support hardware upscaling, the method will return nullptr.

◆ EnumerateVariants()

virtual void DILIGENT_CALL_TYPE Diligent::ISuperResolutionFactory::EnumerateVariants ( Uint32 & NumVariants,
SuperResolutionInfo * Variants )
pure virtual

Enumerates the supported super resolution variants.

Parameters
[in,out]NumVariants- Number of super resolution variants. If Variants is null, this parameter is used to return the number of supported variants. If Variants is not null, this parameter should contain the maximum number of elements to be written to Variants array. It is overwritten with the actual number of variants written to the array.
[out]Variants- Array to receive the supported super resolution variants. Each variant is described by SuperResolutionInfo structure.

◆ GetSourceSettings()

virtual void DILIGENT_CALL_TYPE Diligent::ISuperResolutionFactory::GetSourceSettings ( const SuperResolutionSourceSettingsAttribs & Attribs,
SuperResolutionSourceSettings & Settings ) const
pure virtual

Returns the optimal source (input) settings for super resolution upscaling.

Parameters
[in]Attribs- Attributes, see Diligent::SuperResolutionSourceSettingsAttribs for details.
[out]Settings- On success, receives the optimal source settings, see Diligent::SuperResolutionSourceSettings for details.
Remarks
On backends that don't support hardware upscaling, Settings will be zero-initialized. Use this method to determine the optimal render resolution before creating the upscaler object.

◆ SetBreakOnError()

virtual void DILIGENT_CALL_TYPE Diligent::ISuperResolutionFactory::SetBreakOnError ( bool BreakOnError) const
pure virtual

Sets whether to break program execution on assertion failure.

Parameters
[in]BreakOnError- Whether to break on assertion failure.

◆ SetMemoryAllocator()

virtual void DILIGENT_CALL_TYPE Diligent::ISuperResolutionFactory::SetMemoryAllocator ( IMemoryAllocator * pAllocator) const
pure virtual

Sets the memory allocator to be used by the SuperResolution.

Parameters
[in]pAllocator- Pointer to the memory allocator.

The allocator is a global setting that applies to the entire execution unit (executable or shared library that contains the SuperResolution implementation).

The allocator should be set before any other factory method is called and should not be changed afterwards. The allocator object must remain valid until all objects created by the factory are destroyed.

◆ SetMessageCallback()

virtual void DILIGENT_CALL_TYPE Diligent::ISuperResolutionFactory::SetMessageCallback ( DebugMessageCallbackType MessageCallback) const
pure virtual

Sets a user-provided debug message callback.

Parameters
[in]MessageCallback- Debug message callback function to use instead of the default one.