diff options
| author | assiduous <assiduous@diligentgraphics.com> | 2020-10-28 19:17:06 +0000 |
|---|---|---|
| committer | assiduous <assiduous@diligentgraphics.com> | 2020-10-28 19:17:06 +0000 |
| commit | 5a42a612878339bf3ff765428d668ef207627f91 (patch) | |
| tree | 9fe3004af419b42bc0dea8e78ed10dd93cd58945 /Graphics/GraphicsEngine | |
| parent | Fixed incorrect assert in ReadShaderSourceFile (diff) | |
| download | DiligentCore-5a42a612878339bf3ff765428d668ef207627f91.tar.gz DiligentCore-5a42a612878339bf3ff765428d668ef207627f91.zip | |
Set default swap chain buffer count to 3 on Android and iOS
Diffstat (limited to 'Graphics/GraphicsEngine')
| -rw-r--r-- | Graphics/GraphicsEngine/interface/GraphicsTypes.h | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/Graphics/GraphicsEngine/interface/GraphicsTypes.h b/Graphics/GraphicsEngine/interface/GraphicsTypes.h index b05519c5..e77c3830 100644 --- a/Graphics/GraphicsEngine/interface/GraphicsTypes.h +++ b/Graphics/GraphicsEngine/interface/GraphicsTypes.h @@ -1343,7 +1343,13 @@ struct SwapChainDesc bool IsPrimary DEFAULT_INITIALIZER(true); #if DILIGENT_CPP_INTERFACE - SwapChainDesc()noexcept{} + SwapChainDesc() noexcept + { +#if PLATFORM_ANDROID || PLATFORM_IOS + // Use 3 buffers by default on mobile platforms + BufferCount = 3; +#endif + } /// Constructor intializes the structure members with default values SwapChainDesc(Uint32 _Width, @@ -1362,7 +1368,8 @@ struct SwapChainDesc DefaultDepthValue {_DefaultDepthValue }, DefaultStencilValue {_DefaultStencilValue}, IsPrimary {_IsPrimary } - {} + { + } #endif }; typedef struct SwapChainDesc SwapChainDesc; |
