[SDL] Resize image in SDL_Surface
t1t0 at tiscali.it
Thu Jan 23 18:40:01 PST 2003
Date: Thu, 23 Jan 2003 14:24:17 -0500
From: Glenn Maynard <g_sdl at zewt.org>
To: sdl at libsdl.org
Subject: Re: [SDL] Resize image in SDL_Surface
Reply-To: sdl at libsdl.org
On Thu, Jan 23, 2003 at 01:10:51PM -0600, Corona688 wrote:
> The basic SDL API can't do it; it just loads, converts, and blits
> surfaces. There *is* an add-on library for SDL that can, however. :)
> http://www.ferzkopp.net/Software/SDL_gfx-2.0/ includes image
> stretching, among afew other things. Just be aware that rotozoom
> doesn't stretch the original image - it produces a new, stretched image
> in memory that'll have to be freed once you're done with it by
Also be aware that it's very low-quality; unacceptably low for some size
ratios and uses. (It's written for speed, not quality.)
I've modified the RGBA zoom to do an actual 2:1 sample. It's slower, but
looks better as long as the size ratio isn't worse than 2:1 or 1:2.
I must resize one text image, a pair of times for all the program
I think that will work well.
I still need to add options to handle clamp vs. wrap filtering.
I'm still hoping someone's written a triangle filter resize ...
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: not available
More information about the SDL