From f92524a49f7397c26b10109b1cad1cfede7095ff Mon Sep 17 00:00:00 2001 From: assiduous Date: Tue, 7 Jan 2020 09:14:11 -0800 Subject: Improved reporting of device capabilities (fixed https://github.com/DiligentGraphics/DiligentCore/issues/109) --- Graphics/GraphicsEngine/interface/DeviceCaps.h | 36 +++++++++++++++-------- Graphics/GraphicsEngine/interface/GraphicsTypes.h | 5 ---- 2 files changed, 24 insertions(+), 17 deletions(-) (limited to 'Graphics/GraphicsEngine') diff --git a/Graphics/GraphicsEngine/interface/DeviceCaps.h b/Graphics/GraphicsEngine/interface/DeviceCaps.h index ebde692e..334c28a5 100644 --- a/Graphics/GraphicsEngine/interface/DeviceCaps.h +++ b/Graphics/GraphicsEngine/interface/DeviceCaps.h @@ -52,35 +52,47 @@ namespace Diligent struct SamplerCaps { /// Indicates if device supports border texture addressing mode - Bool bBorderSamplingModeSupported = True; + Bool BorderSamplingModeSupported = False; /// Indicates if device supports anisotrpoic filtering - Bool bAnisotropicFilteringSupported = True; + Bool AnisotropicFilteringSupported = False; /// Indicates if device supports MIP load bias - Bool bLODBiasSupported = True; + Bool LODBiasSupported = False; }; /// Texture capabilities struct TextureCaps { - /// Indicates if device supports 1D textures - Bool bTexture1DSupported = True; + /// Maximum dimension (width) of a 1D texture, or 0 if 1D textures are not supported. + Uint32 MaxTexture1DDimension = 0; - /// Indicates if device supports 1D texture arrays - Bool bTexture1DArraySupported = True; + /// Maximum number of slices in a 1D texture array, or 0 if 1D texture arrays are not supported. + Uint32 MaxTexture1DArraySlices = 0; + + /// Maximum dimension (width or height) of a 2D texture. + Uint32 MaxTexture2DDimension = 0; + + /// Maximum number of slices in a 2D texture array, or 0 if 2D texture arrays are not supported. + Uint32 MaxTexture2DArraySlices = 0; + + /// Maximum dimension (width, height, or depth) of a 3D texture, or 0 if 3D textures are not supported. + Uint32 MaxTexture3DDimension = 0; + + /// Maximum dimension (width or height) of a cubemap face, or 0 if cubemap textures are not supported. + Uint32 MaxTextureCubeDimension = 0; /// Indicates if device supports 2D multisampled textures - Bool bTexture2DMSSupported = True; + Bool Texture2DMSSupported = False; /// Indicates if device supports 2D multisampled texture arrays - Bool bTexture2DMSArraySupported = True; + Bool Texture2DMSArraySupported = False; /// Indicates if device supports texture views - Bool bTextureViewSupported = True; + Bool TextureViewSupported = False; /// Indicates if device supports cubemap arrays - Bool bCubemapArraysSupported = True; + Bool CubemapArraysSupported = False; }; /// Describes supported device features @@ -119,7 +131,7 @@ namespace Diligent /// Indicates if device supports timestamp queries (see Diligent::QUERY_TYPE_TIMESTAMP). Bool TimestampQueries = False; - /// Indicates if device supports timestamp queries (see Diligent::QUERY_TYPE_PIPELINE_STATISTICS). + /// Indicates if device supports pipeline statistics queries (see Diligent::QUERY_TYPE_PIPELINE_STATISTICS). Bool PipelineStatisticsQueries = False; }; diff --git a/Graphics/GraphicsEngine/interface/GraphicsTypes.h b/Graphics/GraphicsEngine/interface/GraphicsTypes.h index 561b8fd8..324a1771 100644 --- a/Graphics/GraphicsEngine/interface/GraphicsTypes.h +++ b/Graphics/GraphicsEngine/interface/GraphicsTypes.h @@ -1498,15 +1498,10 @@ namespace Diligent struct DeviceFeatures { bool depthBiasClamp = false; - bool fillModeNonSolid = false; bool depthClamp = false; bool independentBlend = false; - bool samplerAnisotropy = false; - bool geometryShader = false; - bool tessellationShader = false; bool dualSrcBlend = false; bool multiViewport = false; - bool imageCubeArray = false; bool textureCompressionBC = false; bool vertexPipelineStoresAndAtomics = false; bool fragmentStoresAndAtomics = false; -- cgit v1.2.3