From 5502421901c6e25d186ae5dc4a81b5d3554c1a84 Mon Sep 17 00:00:00 2001 From: Rachael Alexanderson Date: Thu, 1 Jun 2017 16:21:15 -0400 Subject: [PATCH] - fixed: Using pure software drawers (vid_hw2d==false) drawing stencils on the screen resulted in black stencils - this fixes crosshairs being drawn black --- src/swrenderer/r_swcanvas.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/swrenderer/r_swcanvas.cpp b/src/swrenderer/r_swcanvas.cpp index 0448db1ab..3016ae8bb 100644 --- a/src/swrenderer/r_swcanvas.cpp +++ b/src/swrenderer/r_swcanvas.cpp @@ -105,7 +105,8 @@ void SWCanvas::DrawTexture(DCanvas *canvas, FTexture *img, DrawParms &parms) drawerargs.SetTranslationMap(translation); drawerargs.SetLight(basecolormap, 0.0f, shade); - bool visible = drawerargs.SetStyle(viewport, parms.style, parms.Alpha, -1, parms.fillcolor, basecolormap); + uint32_t myfillcolor = (RGB256k.All[((parms.fillcolor & 0xfc0000) >> 6) | ((parms.fillcolor & 0xfc00) >> 4) | ((parms.fillcolor & 0xfc) >> 2)]) << 24; + bool visible = drawerargs.SetStyle(viewport, parms.style, parms.Alpha, -1, myfillcolor, basecolormap); double x0 = parms.x - parms.left * parms.destwidth / parms.texwidth; double y0 = parms.y - parms.top * parms.destheight / parms.texheight;