mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 14:19:46 -06:00
a small fix when not using stretch and a small code move
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@1099 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
@ -541,6 +541,8 @@ void OpenGL_Update()
|
|||||||
#elif defined(_WIN32)
|
#elif defined(_WIN32)
|
||||||
RECT rcWindow;
|
RECT rcWindow;
|
||||||
if (!EmuWindow::GetParentWnd()) {
|
if (!EmuWindow::GetParentWnd()) {
|
||||||
|
if (!g_Config.bStretchToFit)
|
||||||
|
return;
|
||||||
GetWindowRect(EmuWindow::GetWnd(), &rcWindow);
|
GetWindowRect(EmuWindow::GetWnd(), &rcWindow);
|
||||||
rcWindow.top += 25;
|
rcWindow.top += 25;
|
||||||
}
|
}
|
||||||
|
@ -576,6 +576,10 @@ void Renderer::FlushZBufferAlphaToTarget()
|
|||||||
TextureMngr::DisableStage(i);
|
TextureMngr::DisableStage(i);
|
||||||
GL_REPORT_ERRORD();
|
GL_REPORT_ERRORD();
|
||||||
|
|
||||||
|
// setup the stencil to only accept pixels that have been written
|
||||||
|
glStencilFunc(GL_EQUAL, 1, 0xff);
|
||||||
|
glStencilOp(GL_KEEP, GL_KEEP, GL_KEEP);
|
||||||
|
|
||||||
if(g_Config.bStretchToFit)
|
if(g_Config.bStretchToFit)
|
||||||
{
|
{
|
||||||
//TODO: Do Correctly in a bit
|
//TODO: Do Correctly in a bit
|
||||||
@ -597,10 +601,6 @@ void Renderer::FlushZBufferAlphaToTarget()
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// setup the stencil to only accept pixels that have been written
|
|
||||||
glStencilFunc(GL_EQUAL, 1, 0xff);
|
|
||||||
glStencilOp(GL_KEEP, GL_KEEP, GL_KEEP);
|
|
||||||
|
|
||||||
glBegin(GL_QUADS);
|
glBegin(GL_QUADS);
|
||||||
glTexCoord2f(0, 0); glVertex2f(-1,-1);
|
glTexCoord2f(0, 0); glVertex2f(-1,-1);
|
||||||
glTexCoord2f(0, (float)(GetTargetHeight())); glVertex2f(-1,1);
|
glTexCoord2f(0, (float)(GetTargetHeight())); glVertex2f(-1,1);
|
||||||
|
Reference in New Issue
Block a user