mirror of
https://github.com/libretro/RetroArch.git
synced 2024-11-23 16:09:47 +00:00
Apply proper color correction for 16 bits
This commit is contained in:
parent
69ad3273b9
commit
38397370e6
@ -45,7 +45,7 @@ static GSGLOBAL *init_GSGlobal(void) {
|
||||
GSGLOBAL *gsGlobal = gsKit_init_global();
|
||||
|
||||
gsGlobal->PSM = GS_PSM_CT16;
|
||||
gsGlobal->PSMZ = GS_PSMZ_16S;
|
||||
gsGlobal->PSMZ = GS_PSMZ_16;
|
||||
gsGlobal->DoubleBuffering = GS_SETTING_OFF;
|
||||
gsGlobal->ZBuffering = GS_SETTING_OFF;
|
||||
gsGlobal->PrimAlphaEnable = GS_SETTING_OFF;
|
||||
@ -98,7 +98,7 @@ static void color_correction16(uint16_t *buffer, uint32_t dimensions)
|
||||
uint16_t x16;
|
||||
for (i = 0; i < dimensions; i++) {
|
||||
x16 = buffer[i];
|
||||
buffer[i] = (x16 & 0x8000) | ((x16 << 10) & 0x7C00) | (x16 & 0x3E0) | ((x16 >> 10) & 0x1F);
|
||||
buffer[i] = (x16 & 0x8000) | ((x16 << 10) & 0x7C00) | ((x16 >> 1) & 0x3E0) | ((x16 >> 11) & 0x1F);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user