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:
omegadox 2008-11-09 00:28:12 +00:00
parent d2bbd6bda2
commit 42a515ba76
2 changed files with 6 additions and 4 deletions

View File

@ -541,6 +541,8 @@ void OpenGL_Update()
#elif defined(_WIN32)
RECT rcWindow;
if (!EmuWindow::GetParentWnd()) {
if (!g_Config.bStretchToFit)
return;
GetWindowRect(EmuWindow::GetWnd(), &rcWindow);
rcWindow.top += 25;
}

View File

@ -576,6 +576,10 @@ void Renderer::FlushZBufferAlphaToTarget()
TextureMngr::DisableStage(i);
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)
{
//TODO: Do Correctly in a bit
@ -597,10 +601,6 @@ void Renderer::FlushZBufferAlphaToTarget()
}
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);
glTexCoord2f(0, 0); glVertex2f(-1,-1);
glTexCoord2f(0, (float)(GetTargetHeight())); glVertex2f(-1,1);