From e5f352a7e47741e06bd96120d1bd1f8c1f83589a Mon Sep 17 00:00:00 2001 From: David Thompson Date: Sat, 17 Aug 2013 23:52:32 -0400 Subject: Use new color module. --- 2d/helpers.scm | 12 ------------ 1 file changed, 12 deletions(-) (limited to '2d/helpers.scm') diff --git a/2d/helpers.scm b/2d/helpers.scm index 70b9a15..e71d7a1 100644 --- a/2d/helpers.scm +++ b/2d/helpers.scm @@ -37,15 +37,3 @@ otherwise." "Returns true if the result of a bitwise AND of the integer arguments is non-zero and returns false otherwise." (not (zero? (apply logand args)))) - -(define (rgba->gl-color color) - "Converts an integer color code into OpenGL compatible color -values. Returns a vector of four floating point numbers in range [0,1]." - (define (component offset) - (let ((mask (bitwise-arithmetic-shift-left #xff offset))) - (/ (bitwise-arithmetic-shift-right (logand mask color) offset) 255.0))) - - (vector (component 24) - (component 16) - (component 8) - (component 0))) -- cgit v1.2.3