diff --git a/OpenRa.Gl/GraphicsDevice.cs b/OpenRa.Gl/GraphicsDevice.cs index 4024c7eb22..97ac9da2a6 100644 --- a/OpenRa.Gl/GraphicsDevice.cs +++ b/OpenRa.Gl/GraphicsDevice.cs @@ -13,6 +13,7 @@ namespace OpenRa.GlRenderer { public class GraphicsDevice { + Size windowSize; Graphics g; internal IntPtr dc; internal IntPtr rc; @@ -28,6 +29,7 @@ namespace OpenRa.GlRenderer public GraphicsDevice(Control control, int width, int height, bool fullscreen, bool vsync) { + windowSize = new Size( width, height ); g = control.CreateGraphics(); dc = g.GetHdc(); @@ -75,7 +77,7 @@ namespace OpenRa.GlRenderer { if( width < 0 ) width = 0; if( height < 0 ) height = 0; - Gl.glScissor(left, top, width, height); + Gl.glScissor( left, windowSize.Height - ( top + height ), width, height ); CheckGlError(); Gl.glEnable(Gl.GL_SCISSOR_TEST); CheckGlError(); diff --git a/chrome-shp.fx b/chrome-shp.fx index 72e3af8cb4..d695ac4047 100644 --- a/chrome-shp.fx +++ b/chrome-shp.fx @@ -57,10 +57,14 @@ float4 Palette_fp(VertexOut f) : COLOR0 { technique low_quality { pass p0 { - BlendEnable = false; + BlendEnable = true; DepthTestEnable = false; CullFaceEnable = false; VertexProgram = compile latest Simple_vp(); FragmentProgram = compile latest Palette_fp(); + + BlendEquation = FuncAdd; + BlendFunc = int2( SrcAlpha, OneMinusSrcAlpha ); } } +