On Tue, 12 May 2009 20:02:41 -0700, Elliott Slaughter
<[email protected]> wrote:
> Hi,
>
> I was chasing a bug recently, and in the process found some odd behavior
> in
> sdl-gfx:zoom-surface. Using the attached gif image (a solid green
> square),
> only the non-zoomed image shows up (the other one gets a color-key set
> for
> some reason). Oddly enough, both zoomed and normal work fine with the
> attached bmp image.
>
"square.gif" is a 1-bit image that SDL_image converts to an 8-bit surface.
It seems that the SDL_gfx zoom function has a problem with 8-bit images.
The following is a bit clunky, but converting the surface to 32-bit prior
to zooming seems to work.
(zoom (sdl:convert-to-display-format
:surface (sdl-gfx:zoom-surface
2 2 :surface (sdl:convert-to-display-format
:surface (sdl-image:load-image
"square.gif")))))
- Luke
_______________________________________________
application-builder mailing list
[email protected]
http://www.lispniks.com/mailman/listinfo/application-builder