Function: shr-color-hsl-to-rgb-fractions

shr-color-hsl-to-rgb-fractions is a byte-compiled function defined in shr-color.el.gz.

Signature

(shr-color-hsl-to-rgb-fractions H S L)

Documentation

Convert H S L to fractional RGB values.

Source Code

;; Defined in /usr/src/emacs/lisp/net/shr-color.el.gz
(defun shr-color-hsl-to-rgb-fractions (h s l)
  "Convert H S L to fractional RGB values."
  (let (m1 m2)
    (if (<= l 0.5)
        (setq m2 (* l (+ s 1)))
        (setq m2 (- (+ l s) (* l s))))
    (setq m1 (- (* l 2) m2))
    (list (shr-color-hue-to-rgb m1 m2 (+ h (/ 3.0)))
	  (shr-color-hue-to-rgb m1 m2 h)
	  (shr-color-hue-to-rgb m1 m2 (- h (/ 3.0))))))