Welcome to the CHICKEN Scheme pasting service

fps color conversion routine added by C-Keen on Tue Jan 17 16:28:54 2012

(define (hsb->rgb h s b) 
  (if (= s 0) 
      (rgb b b b)
      (let* ((i (floor (* h 6)))
	     (f (- (* h 6) i))
	     (p (* b (- 1 s)))
	     (q (* b (- 1 (* s f))))
	     (t (* b (- 1 (* s (- 1 f))))))
	(case (if (inexact? i) (inexact->exact i) i)
	  ((0 6) (rgb b t p))
	  ((1) (rgb q b p))
	  ((2) (rgb p b t))
	  ((3) (rgb p q b))
	  ((4) (rgb t p b))
	  ((5) (rgb b p q))
	  (else (internal-bug hsb->rgb
			      "is an illegal hsb remainder value" i))))))

Your annotation:

Enter a new annotation:

Your nick:
The title of your paste:
Your paste (mandatory) :
What does `(string? "foo")' produce?
Visually impaired? Let me spell it for you (wav file) download WAV