Actual explaination about this (nw)

This commit is contained in:
angelosa 2018-02-19 00:35:09 +01:00
parent 079bc478a3
commit d5b6deeca2

View File

@ -185,13 +185,14 @@ void MODEL2_FUNC_NAME(int32_t scanline, const extent_t& extent, const m2_poly_ex
// Virtua Striker sets up a luma of 0x40 for national flags on bleachers, fix here. // Virtua Striker sets up a luma of 0x40 for national flags on bleachers, fix here.
luma = std::min((int)luma,0x3f); luma = std::min((int)luma,0x3f);
// (Again) Virtua Striker seem to lookup colortable with a reversed endianness (stadium ads)
luma^= 1;
/* we have the 6 bits of luma information along with 5 bits per color component */ /* we have the 6 bits of luma information along with 5 bits per color component */
/* now build and index into the master color lookup table and extract the raw RGB values */ /* now build and index into the master color lookup table and extract the raw RGB values */
tr = colortable_r[(luma)] & 0xff;
tr = colortable_r[(luma^1)] & 0xff; tg = colortable_g[(luma)] & 0xff;
tg = colortable_g[(luma^1)] & 0xff; tb = colortable_b[(luma)] & 0xff;
tb = colortable_b[(luma^1)] & 0xff;
tr = gamma_value[tr]; tr = gamma_value[tr];
tg = gamma_value[tg]; tg = gamma_value[tg];
tb = gamma_value[tb]; tb = gamma_value[tb];