]> Dogcows Code - chaz/openbox/commitdiff
use the pseudo shit in the instance now
authorDana Jansens <danakj@orodu.net>
Sat, 21 Jun 2003 02:38:47 +0000 (02:38 +0000)
committerDana Jansens <danakj@orodu.net>
Sat, 21 Jun 2003 02:38:47 +0000 (02:38 +0000)
render/color.c

index 564fb7cf8edbfba6aad93a5060a09e7f98155a66..b485685379c390c427b3900dcadaaf6af2ffaa85 100644 (file)
@@ -4,9 +4,6 @@
 #include "render.h"
 #include "color.h"
 
-XColor *pseudo_colors;
-int pseudo_bpc;
-
 void RrColorAllocateGC(RrColor *in)
 {
     XGCValues gcv;
@@ -130,11 +127,11 @@ void RrReduceDepth(const RrInstance *inst, RrPixel32 *data, XImage *im)
 
 XColor *RrPickColor(const RrInstance *inst, gint r, gint g, gint b) 
 {
-  r = (r & 0xff) >> (8-pseudo_bpc);
-  g = (g & 0xff) >> (8-pseudo_bpc);
-  b = (b & 0xff) >> (8-pseudo_bpc);
-  return &RrPseudoColors(inst)[(r << (2*pseudo_bpc)) +
-                               (g << (1*pseudo_bpc)) +
+  r = (r & 0xff) >> (8-RrPseudoBPC(inst));
+  g = (g & 0xff) >> (8-RrPseudoBPC(inst));
+  b = (b & 0xff) >> (8-RrPseudoBPC(inst));
+  return &RrPseudoColors(inst)[(r << (2*RrPseudoBPC(inst))) +
+                               (g << (1*RrPseudoBPC(inst))) +
                                b];
 }
 
This page took 0.025936 seconds and 4 git commands to generate.