$Id$
$URL$
"""
+from colorsys import hls_to_rgb
+from math import floor
BACKGROUND_LAYER = 0
FOREGROUND_LAYER = 1
,'NORMAL':1
,'ADVANCED':2
,'EXPERT':3}
+
+def hls_to_rgba_8bits(h, l, s, a=1) :
+ #convert to rgb ranging from 0 to 255
+ rgba = [floor(255 * i) for i in hls_to_rgb(h, l, s) + (a,)]
+ return tuple(rgba)
+