QfFdZgdZdZdZdZdZdZdZdZd Z d Z d Z y ) aJConversion functions between RGB and other color systems. This modules provides two functions for each color system ABC: rgb_to_abc(r, g, b) --> a, b, c abc_to_rgb(a, b, c) --> r, g, b All inputs and outputs are triples of floats in the range [0.0...1.0] (with the exception of I and Q, which covers a slightly larger range). Inputs outside the valid range may cause exceptions or invalid outputs. Supported color systems: RGB: Red, Green, Blue components YIQ: Luminance, Chrominance (used by composite video signals) HLS: Hue, Luminance, Saturation HSV: Hue, Saturation, Value ) rgb_to_yiq yiq_to_rgb rgb_to_hls hls_to_rgb rgb_to_hsv hsv_to_rgbgUUUUUU?gUUUUUU?gUUUUUU?crd|zd|zzd|zz}d||z zd||z zz }d||z zd||z zz}|||fS)Ng333333?gzG?g)\(?gGz?gHzG?gQ?g= ףp=?)rgbyiqs //opt/alt/python312/lib64/python3.12/colorsys.pyrr(s\ Qa$q& A ac T1Q3ZA ac T1Q3ZA q!9c|d|zzd|zz}|d|zz d|zz }|d|zz d|zz}|dkrd}|dkrd}|dkrd}|dkDrd}|dkDrd}|dkDrd}|||fS) Ng2rL?g,?g:?gnєW?g6޷?gJ"X??r )r rrr r r s rrr.s q  #5a#77A  !!$6q$88A q  #5a#77A3w 3w 3w 3w 3w 3w  q!9rc t|||}t|||}||z}||z }|dz }||k(rd|dfS|dkr||z }n |d|z |z z }||z |z } ||z |z } ||z |z } ||k(r| | z } n||k(r d| z| z } nd| z| z } | dz dz} | ||fS)N@r?@@rmaxmin) r r r maxcmincsumcrangeclsrcgcbchs rrrKs q!Qr@sF. &     :0M (r