Hi,

I've been playing around with using SDL_gfx to zoom surfaces, and ran into a
bit of trouble with color-keys. I eventually got the following to work:

(let ((surface
         (sdl:convert-to-display-format
          :surface (sdl-gfx:zoom-surface
                    zoomx zoomy
                    :surface (sdl-image:load-image source))
          :inherit nil)))
    (setf (sdl:color-key-enabled-p surface) color-key
          (sdl:color-key surface) (sdl:color ...))
    surface)

The above code works as it is, but fails if I remove :inherit nil from the
call to convert-to-display-format.

I'm just wondering why zoom-surface fails to create a surface capable of
color-key blending, and if there is any way better than the above for
accomplishing that.

Thanks.

-- 
Elliott Slaughter

"Any road followed precisely to its end leads precisely nowhere." - Frank
Herbert
_______________________________________________
application-builder mailing list
application-builder@lispniks.com
http://www.lispniks.com/mailman/listinfo/application-builder

Reply via email to