summaryrefslogtreecommitdiff
path: root/atari/plot
diff options
context:
space:
mode:
Diffstat (limited to 'atari/plot')
-rwxr-xr-xatari/plot/plot.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/atari/plot/plot.c b/atari/plot/plot.c
index 2c75db335..e29347f02 100755
--- a/atari/plot/plot.c
+++ b/atari/plot/plot.c
@@ -635,7 +635,7 @@ inline short rgb_to_666_index(unsigned char r, unsigned char g, unsigned char b)
diff_b = abs(r-b);
diff_c = abs(r-b);
if( diff_a < 2 && diff_b < 2 && diff_c < 2 ) {
- if( (r!=0XFF) && (g!=0XFF) && (g!=0XFF) ) {
+ if( (r!=0XFF) && (g!=0XFF) && (b!=0XFF) ) {
if( ((r&0xF0)>>4) != 0 )
//printf("conv gray: %x -> %d\n", ((r&0xF0)>>4) , (OFFSET_CUST_PAL) + ((r&0xF0)>>4) );
return( (OFFSET_CUST_PAL - OFFSET_WEB_PAL) + ((r&0xF0)>>4) );