- always store 255 in alpha channel for opaque things as the alpha channel is no longer ignored by the framebuffer backend (software drawer)

(cherry picked from commit 25784c2e57)
This commit is contained in:
Magnus Norddahl 2018-04-15 14:58:19 +02:00 committed by drfrag666
parent 90e131b6fd
commit b07c4c41c7
6 changed files with 6 additions and 0 deletions

View file

@ -371,6 +371,7 @@ namespace swrenderer
if (BlendT::Mode == (int)SpanBlendModes::Opaque)
{
fgcolor.a = 255;
return fgcolor;
}
else if (BlendT::Mode == (int)SpanBlendModes::Masked)

View file

@ -414,6 +414,7 @@ namespace swrenderer
{
__m128i outcolor = fgcolor;
outcolor = _mm_packus_epi16(outcolor, _mm_setzero_si128());
outcolor = _mm_or_si128(outcolor, _mm_set1_epi32(0xff000000));
return outcolor;
}
else if (BlendT::Mode == (int)SpanBlendModes::Masked)

View file

@ -322,6 +322,7 @@ namespace swrenderer
if (BlendT::Mode == (int)SpriteBlendModes::Opaque)
{
fgcolor.a = 255;
return fgcolor;
}
else if (BlendT::Mode == (int)SpriteBlendModes::Shaded)

View file

@ -368,6 +368,7 @@ namespace swrenderer
{
__m128i outcolor = fgcolor;
outcolor = _mm_packus_epi16(outcolor, _mm_setzero_si128());
outcolor = _mm_or_si128(outcolor, _mm_set1_epi32(0xff000000));
return outcolor;
}
else if (BlendT::Mode == (int)SpriteBlendModes::Shaded)

View file

@ -285,6 +285,7 @@ namespace swrenderer
if (BlendT::Mode == (int)WallBlendModes::Opaque)
{
fgcolor.a = 255;
return fgcolor;
}
else if (BlendT::Mode == (int)WallBlendModes::Masked)

View file

@ -330,6 +330,7 @@ namespace swrenderer
{
__m128i outcolor = fgcolor;
outcolor = _mm_packus_epi16(outcolor, _mm_setzero_si128());
outcolor = _mm_or_si128(outcolor, _mm_set1_epi32(0xff000000));
return outcolor;
}
else if (BlendT::Mode == (int)WallBlendModes::Masked)