From 564cf2dac14c168c961f43957ed5dcff24e0cd2c Mon Sep 17 00:00:00 2001 From: omegadox Date: Sun, 22 Mar 2009 13:25:05 +0000 Subject: [PATCH] Wireframe will work in AA mode now. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2729 8ced0084-cf51-0410-be5f-012b33b47a6e --- Source/Plugins/Plugin_VideoOGL/Src/Render.cpp | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/Source/Plugins/Plugin_VideoOGL/Src/Render.cpp b/Source/Plugins/Plugin_VideoOGL/Src/Render.cpp index d7a303b3ba..5042af03aa 100644 --- a/Source/Plugins/Plugin_VideoOGL/Src/Render.cpp +++ b/Source/Plugins/Plugin_VideoOGL/Src/Render.cpp @@ -1010,6 +1010,8 @@ void Renderer::Swap(const TRectangle& rc) v_max = (float)GetTargetHeight(); } + glPolygonMode(GL_FRONT_AND_BACK, GL_FILL); + if (/*s_bHaveFramebufferBlit*/ s_MSAASamples > 1) { // Use framebuffer blit to stretch screen. @@ -1055,7 +1057,6 @@ void Renderer::Swap(const TRectangle& rc) glTexParameteri(GL_TEXTURE_RECTANGLE_ARB, GL_TEXTURE_MAG_FILTER, GL_LINEAR); glTexParameteri(GL_TEXTURE_RECTANGLE_ARB, GL_TEXTURE_MIN_FILTER, GL_LINEAR); - glPolygonMode(GL_FRONT_AND_BACK, GL_FILL); glBegin(GL_QUADS); glTexCoord2f(0, v_min); glVertex2f(-1, -1); glTexCoord2f(0, v_max); glVertex2f(-1, 1); @@ -1067,15 +1068,15 @@ void Renderer::Swap(const TRectangle& rc) glTexParameteri(GL_TEXTURE_RECTANGLE_ARB, GL_TEXTURE_MAG_FILTER, GL_NEAREST); glTexParameteri(GL_TEXTURE_RECTANGLE_ARB, GL_TEXTURE_MIN_FILTER, GL_NEAREST); - // Wireframe - if (g_Config.bWireFrame) - glPolygonMode(GL_FRONT_AND_BACK, GL_LINE); - glBindTexture(GL_TEXTURE_RECTANGLE_ARB, 0); TextureMngr::DisableStage(0); // End of non-framebuffer_blit workaround. } + // Wireframe + if (g_Config.bWireFrame) + glPolygonMode(GL_FRONT_AND_BACK, GL_LINE); + // Take screenshot, if requested if (s_bScreenshot) { s_criticalScreenshot.Enter();