Skip to content

Commit

Permalink
Test for transparency before dithering.
Browse files Browse the repository at this point in the history
  • Loading branch information
bearoso committed May 6, 2018
1 parent 113a43c commit bd9db57
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions fxinst.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -906,14 +906,14 @@ static void fx_plot_2bit (void)
return;
#endif

if (!(GSU.vPlotOptionReg & 0x01) && !(COLR & 0xf))
return;

if (GSU.vPlotOptionReg & 0x02)
c = ((x ^ y) & 1) ? (uint8) (GSU.vColorReg >> 4) : (uint8) GSU.vColorReg;
else
c = (uint8) GSU.vColorReg;

if (!(GSU.vPlotOptionReg & 0x01) && !(c & 0xf))
return;

a = GSU.apvScreen[y >> 3] + GSU.x[x >> 3] + ((y & 7) << 1);
v = 128 >> (x & 7);

Expand Down Expand Up @@ -970,14 +970,14 @@ static void fx_plot_4bit (void)
return;
#endif

if (!(GSU.vPlotOptionReg & 0x01) && !(COLR & 0xf))
return;

if (GSU.vPlotOptionReg & 0x02)
c = ((x ^ y) & 1) ? (uint8) (GSU.vColorReg >> 4) : (uint8) GSU.vColorReg;
else
c = (uint8) GSU.vColorReg;

if (!(GSU.vPlotOptionReg & 0x01) && !(c & 0xf))
return;

a = GSU.apvScreen[y >> 3] + GSU.x[x >> 3] + ((y & 7) << 1);
v = 128 >> (x & 7);

Expand Down

0 comments on commit bd9db57

Please sign in to comment.