I thought I'd post here as I think grand master Stef is busy
Does anyone know how rescomp decides upon the colours it uses for conversion?
Does it use standard 9-bit colour RGB values
0, 32, 64, 96, 128, 160, 192, 224, 256
Old incorrect linear levels RGB values
0, 36, 72, 108, 144, 180, 216, 252/255
Or Tiido's Nonlinear levels RGB values
0, 52, 87, 116, 144, 172, 206, 255
Rescomp colour conversion
Moderator: Stef
Re: Rescomp colour conversion
Looks like it uses the standard.
In tools/rescomp/src/tools.c:
In tools/rescomp/src/tools.c:
Code: Select all
unsigned short toVDPColor(unsigned char b, unsigned char g, unsigned char r)
{
// genesis only define on 3 bits (but shifted to 1 left)
r = (r >> 4) & 0xE;
g = (g >> 4) & 0xE;
b = (b >> 4) & 0xE;
return (r << 0) | (g << 4) | (b << 8);
}
Re: Rescomp colour conversion
Huh... I just did some checks and if you take Tiido's values and leave only the higher three bits (like rescomp does) it actually gives the correct result. Go figure.
Sik is pronounced as "seek", not as "sick".
-
- Very interested
- Posts: 2442
- Joined: Tue Dec 05, 2006 1:37 pm
- Location: Estonia, Rapla City
- Contact:
Re: Rescomp colour conversion
I just do 255/34 in my tools and it works for linear and the nonlinear ramp too.
Mida sa loed ? Nagunii aru ei saa
http://www.tmeeco.eu
Files of all broken links and images of mine are found here : http://www.tmeeco.eu/FileDen
http://www.tmeeco.eu
Files of all broken links and images of mine are found here : http://www.tmeeco.eu/FileDen