Skip to content

Commit

Permalink
[WIN32] workaround for nVidia texture corruption issue in GUI (ticket #…
Browse files Browse the repository at this point in the history
…9269)

(cherry picked from commit a07d767fe643b24d1d4f172f900aa6c27976be19)

git-svn-id: https://xbmc.svn.sourceforge.net/svnroot/xbmc/branches/Dharma@33077 568bbfeb-2a22-0410-94d2-cc84cf5bfa90
  • Loading branch information
CrystalPT authored and CrystalPT committed Aug 23, 2010
1 parent 803fa69 commit e328d79
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions xbmc/RenderSystemDX.cpp
Expand Up @@ -479,6 +479,19 @@ bool CRenderSystemDX::CreateDevice()
if (m_renderCaps & RENDER_CAPS_DXT_NPOT)
CLog::Log(LOGDEBUG, __FUNCTION__" - RENDER_CAPS_DXT_NPOT");

// nVidia quirk: some NPOT DXT textures of the GUI display with corruption
// when using D3DPOOL_DEFAULT + D3DUSAGE_DYNAMIC textures (no other choice with D3D9Ex for example)
// most likely xbmc bug, but no hw to repro & fix properly.
// affects lots of hw generations - 6xxx, 7xxx, GT220, ION1
// see ticket #9269
if(m_defaultD3DUsage == D3DUSAGE_DYNAMIC
&& m_defaultD3DPool == D3DPOOL_DEFAULT
&& AIdentifier.VendorId == 4318)
{
CLog::Log(LOGDEBUG, __FUNCTION__" - nVidia workaround - disabling RENDER_CAPS_DXT_NPOT");
m_renderCaps &= ~RENDER_CAPS_DXT_NPOT;
}

D3DDISPLAYMODE mode;
if (SUCCEEDED(m_pD3DDevice->GetDisplayMode(0, &mode)))
m_screenHeight = mode.Height;
Expand Down

0 comments on commit e328d79

Please sign in to comment.