]> git.jsancho.org Git - gacela.git/commitdiff
(no commit message)
authorjsancho <devnull@localhost>
Sat, 18 Jun 2011 07:57:33 +0000 (07:57 +0000)
committerjsancho <devnull@localhost>
Sat, 18 Jun 2011 07:57:33 +0000 (07:57 +0000)
src/gacela.scm

index 26a1e9cf93bd1935d17d289c78e090f0f461b308..54b705fcf4f0553840f7fbb7095448525c61fe59 100644 (file)
          (set! current-color (list red green blue alpha))
          (glColor4f red green blue alpha))))
 
-(define* (load-image image-file #:key transparent-color)
-  (init-video-mode)
-  (let ((loaded-image (IMG_Load image-file)))
-    (cond ((= loaded-image 0) #f)
-         (else (let ((optimized-image (SDL_DisplayFormat loaded-image)))
-                 (SDL_FreeSurface loaded-image)
-                 (cond ((= optimized-image 0) #f)
-                       ((not transparent-color) optimized-image)
-                       (else (SDL_SetColorKey optimized-image
-                                              SDL_SRCCOLORKEY
-                                              (SDL_MapRGB (surface-format optimized-image)
-                                                          (car transparent-color)
-                                                          (cadr transparent-color)
-                                                          (caddr transparent-color)))
-                             optimized-image)))))))
-
 
 ;;; Audio Subsystem