Skip to content

Commit

Permalink
More cleanups.
Browse files Browse the repository at this point in the history
  • Loading branch information
neobrain committed Oct 3, 2012
1 parent 6e4a61a commit 8f5223d
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 25 deletions.
16 changes: 8 additions & 8 deletions Source/Plugins/Plugin_VideoDX11/Src/Render.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -974,7 +974,14 @@ void Renderer::Swap(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight,cons

MathUtil::Rectangle<float> drawRc;

if (g_ActiveConfig.bUseXFB && !g_ActiveConfig.bUseRealXFB)
if (g_ActiveConfig.bUseRealXFB)
{
drawRc.top = 1;
drawRc.bottom = -1;
drawRc.left = -1;
drawRc.right = 1;
}
else
{
// use virtual xfb with offset
int xfbHeight = xfbSource->srcHeight;
Expand All @@ -995,13 +1002,6 @@ void Renderer::Swap(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight,cons
//drawRc.left *= hScale;
//drawRc.right *= hScale;
}
else
{
drawRc.top = 1;
drawRc.bottom = -1;
drawRc.left = -1;
drawRc.right = 1;
}

xfbSource->Draw(sourceRc, drawRc, 0, 0);
}
Expand Down
16 changes: 8 additions & 8 deletions Source/Plugins/Plugin_VideoDX9/Src/Render.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -949,7 +949,14 @@ void Renderer::Swap(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight,cons

MathUtil::Rectangle<float> drawRc;

if (!g_ActiveConfig.bUseRealXFB)
if (g_ActiveConfig.bUseRealXFB)
{
drawRc.top = -1;
drawRc.bottom = 1;
drawRc.left = -1;
drawRc.right = 1;
}
else
{
// use virtual xfb with offset
int xfbHeight = xfbSource->srcHeight;
Expand All @@ -970,13 +977,6 @@ void Renderer::Swap(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight,cons
//drawRc.left *= hScale;
//drawRc.right *= hScale;
}
else
{
drawRc.top = -1;
drawRc.bottom = 1;
drawRc.left = -1;
drawRc.right = 1;
}

xfbSource->Draw(sourceRc, drawRc, Width, Height);
}
Expand Down
17 changes: 8 additions & 9 deletions Source/Plugins/Plugin_VideoOGL/Src/Render.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1067,7 +1067,14 @@ void Renderer::Swap(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight,cons

MathUtil::Rectangle<float> drawRc;

if (!g_ActiveConfig.bUseRealXFB)
if (g_ActiveConfig.bUseRealXFB)
{
drawRc.top = 1;
drawRc.bottom = -1;
drawRc.left = -1;
drawRc.right = 1;
}
else
{
// use virtual xfb with offset
int xfbHeight = xfbSource->srcHeight;
Expand All @@ -1088,14 +1095,6 @@ void Renderer::Swap(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight,cons
//drawRc.left *= hScale;
//drawRc.right *= hScale;
}
else
{
drawRc.top = 1;
drawRc.bottom = -1;
drawRc.left = -1;
drawRc.right = 1;
}

// Tell the OSD Menu about the current internal resolution
OSDInternalW = xfbSource->sourceRc.GetWidth(); OSDInternalH = xfbSource->sourceRc.GetHeight();

Expand Down

0 comments on commit 8f5223d

Please sign in to comment.