Translate old colour codes


Re: Translate old colour codes
#2
Yes, you only need to calculate the RGB of the dithered color code by applying the known base colors from the LDConfig, like so (c++ pseudo)

Code:
A=(code-256) >> 4
B=(code-256) & 0x0F

r=(A.r+B.r)/2.0
g=(A.g+B.g)/2.0
b=(A.b+B.b)/2.0

edit: forgot the -256
Reply
« Next Oldest | Next Newest »



Messages In This Thread
Re: Translate old colour codes - by Roland Melkert - 2015-01-22, 23:23

Forum Jump:


Users browsing this thread: 3 Guest(s)