GB Video: Fix color scaling in AGB mode

This commit is contained in:
Vicki Pfau 2019-10-02 18:05:54 -07:00
parent 68af1131aa
commit ed6d55bc46
2 changed files with 4 additions and 0 deletions

View File

@ -34,6 +34,7 @@ Emulation fixes:
- GB Memory: Better emulate 0xFEA0 region on DMG, MGB and AGB
- GB Video: Fix mode 0 window edge case (fixes mgba.io/i/1519)
- GB Audio: Fix channel 4 volume (fixes mgba.io/i/1529)
- GB Video: Fix color scaling in AGB mode
Other fixes:
- Qt: Fix some Qt display driver race conditions
- Core: Improved lockstep driver reliability (Le Hoang Quyen)

View File

@ -461,8 +461,11 @@ static void GBVideoSoftwareRendererWritePalette(struct GBVideoRenderer* renderer
color = mColorFrom555(r | (g << 5) | (b << 10));
#else
r >>= 2;
r += r >> 4;
g >>= 2;
g += g >> 4;
b >>= 2;
b += b >> 4;
color = r | (g << 8) | (b << 16);
#endif
}