Skip to content

Commit

Permalink
[RenderSystemDX] increase buffer count. this improve performance on l…
Browse files Browse the repository at this point in the history
…ow powered systems.
  • Loading branch information
Anton Fedchin committed Apr 24, 2016
1 parent 49e0dde commit f0b95b4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions xbmc/rendering/dx/RenderSystemDX.cpp
Expand Up @@ -840,7 +840,7 @@ bool CRenderSystemDX::CreateWindowSizeDependentResources()
DXGI_SWAP_CHAIN_DESC1 scDesc1 = { 0 };
scDesc1.Width = m_nBackBufferWidth;
scDesc1.Height = m_nBackBufferHeight;
scDesc1.BufferCount = 2 + 3 * bHWStereoEnabled;
scDesc1.BufferCount = 3 * (1 + bHWStereoEnabled);
scDesc1.Format = DXGI_FORMAT_B8G8R8A8_UNORM;
scDesc1.BufferUsage = DXGI_USAGE_RENDER_TARGET_OUTPUT;
scDesc1.AlphaMode = DXGI_ALPHA_MODE_UNSPECIFIED;
Expand Down Expand Up @@ -891,7 +891,7 @@ bool CRenderSystemDX::CreateWindowSizeDependentResources()
else
{
// DirectX 11.0 systems
scDesc.BufferCount = 2; // Use double buffering to minimize latency.
scDesc.BufferCount = 3;
scDesc.BufferUsage = DXGI_USAGE_RENDER_TARGET_OUTPUT;
scDesc.OutputWindow = m_hFocusWnd;
scDesc.Windowed = m_useWindowedDX;
Expand Down

3 comments on commit f0b95b4

@FernetMenta
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you know that this ruins a/v sync, don't you?

@afedchin
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this includes front buffer also, iirc we expect triple buffering, don't we?

@FernetMenta
Copy link
Contributor

@FernetMenta FernetMenta commented on f0b95b4 Apr 25, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nope, we expect double buffers. this is why I did this: #8675
If you have time, you are welcome to finish it

Please sign in to comment.