This is for people involved in the developement of Snes9x, or SNES emulators in general.
BUG REPORTS BELONG IN TECH SUPPORT/BUG TRACKING!
-
Zenju
- Snes9x White Belt
- Posts: 16
- Joined: Mon May 19, 2014 4:46 pm
Post
by Zenju »
Hi,
for the Windows port the RGB565 to RGB32 is implemented as:
Code: Select all
#define CONVERT_16_TO_32(pixel)
(((((pixel) >> 11) ) << /*RedShift+3*/ 19) |
((((pixel) >> 6) & 0x1f) << /*GreenShift+3*/11) |
(((pixel) & 0x1f) << /*BlueShift+3*/ 3))
The green pixel needlessly is stripped off its least significant bit, i.e. instad of 6 it is treated as a 5-bit color. Here's the fix:
Code: Select all
((((pixel) >> 5) & 0x3f) << /*GreenShift+2*/10) |
Regards, Zenju
-
OV2
- Official Win32 Porter/Dev
- Posts: 679
- Joined: Thu Aug 30, 2007 10:15 pm
Post
by OV2 »
I've already applied it. Now I just need to find some time for xbrz...