Skip to content

Commit

Permalink
Merge pull request #13819 from Rechi/windowsRenderInfo
Browse files Browse the repository at this point in the history
[windows] set GPU & D3D version for SettingsSystemInfo window
  • Loading branch information
Rechi committed Apr 26, 2018
2 parents 2f5f0c0 + 08276ee commit 1f8a535
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions xbmc/rendering/dx/RenderSystemDX.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,14 @@ bool CRenderSystemDX::InitRenderSystem()
CPoint camPoint = { outputSize.Width * 0.5f, outputSize.Height * 0.5f };
SetCameraPosition(camPoint, outputSize.Width, outputSize.Height);

DXGI_ADAPTER_DESC AIdentifier = { 0 };
m_deviceResources->GetAdapterDesc(&AIdentifier);
m_RenderRenderer = KODI::PLATFORM::WINDOWS::FromW(AIdentifier.Description);
uint32_t version = 0;
for (uint32_t decimal = m_deviceResources->GetDeviceFeatureLevel() >> 8, round = 0; decimal > 0; decimal >>= 4, ++round)
version += (decimal % 16) * std::pow(10, round);
m_RenderVersion = StringUtils::Format("%.1f", static_cast<float>(version) / 10.0f);

return true;
}

Expand Down

0 comments on commit 1f8a535

Please sign in to comment.