From 994ff6bfd803edd76f45e7b2e083c2bbd06e0cf3 Mon Sep 17 00:00:00 2001 From: brunzelchen Date: Wed, 7 Apr 2010 20:17:42 +0000 Subject: - fixed "vista-no-mic-leads-to-crash" bug - better fading texture handling - fixed black video background on second screen in song menu - "Blue Sensation" as default theme git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/branches/1.0.1 Challenge MOD@2224 b956fd51-792f-4845-bead-9b4dfca2ff2c --- Game/Code/Classes/UVideo.pas | 26 ++++++++++++++++++-------- 1 file changed, 18 insertions(+), 8 deletions(-) (limited to 'Game/Code/Classes/UVideo.pas') diff --git a/Game/Code/Classes/UVideo.pas b/Game/Code/Classes/UVideo.pas index b37166c1..9e04a8ec 100644 --- a/Game/Code/Classes/UVideo.pas +++ b/Game/Code/Classes/UVideo.pas @@ -767,14 +767,23 @@ var begin // have a nice black background to draw on (even if there were errors opening the vid) - if (Screen=1) and not Window.windowed then begin + if Not Window.windowed then + begin glDisable(GL_BLEND); //glDisable(GL_DEPTH_TEST); //glDepthMask(GL_FALSE); //glDisable(GL_CULL_FACE); + + glScissor(round((ScreenW/Screens)*(Screen-1)), + 0, + round(ScreenW/Screens), + round(ScreenH)); + glEnable(GL_SCISSOR_TEST); glClearColor(0,0,0,1); glClear(GL_COLOR_BUFFER_BIT or GL_DEPTH_BUFFER_BIT); + + glDisable(GL_SCISSOR_TEST); end else glEnable(GL_BLEND); @@ -786,13 +795,14 @@ begin GetVideoRect(ScreenRect, TexRect, Window); - - glScissor(round((Window.Left)*(ScreenW/Screens)/RenderW+(ScreenW/Screens)*(Screen-1)), - round((RenderH-Window.Lower)*ScreenH/RenderH), - round((Window.Right-Window.Left)*(ScreenW/Screens)/RenderW), - round((Window.Lower-Window.Upper)*ScreenH/RenderH)); - glEnable(GL_SCISSOR_TEST); - + if Window.windowed then + begin + glScissor(round((Window.Left)*(ScreenW/Screens)/RenderW+(ScreenW/Screens)*(Screen-1)), + round((RenderH-Window.Lower)*ScreenH/RenderH), + round((Window.Right-Window.Left)*(ScreenW/Screens)/RenderW), + round((Window.Lower-Window.Upper)*ScreenH/RenderH)); + glEnable(GL_SCISSOR_TEST); + end; glEnable(GL_TEXTURE_2D); glColor4f(1, 1, 1, Blend); -- cgit v1.2.3