It is what imagmagik do, in C/C++ and many other languages.
Of course Imagmagick deal with proper image format but it is very easy to convert it in SDL surface.
I use it in some SDL projects (all sort of image transformation and distorsion, various effects…)and work very well.
-----Messaggio originale-----Da: sdl-bounces at lists.libsdl.org [mailto:sdl-bounces at lists.libsdl.org] Per conto di neil at cloudsprinter.com
Inviato: mercoled? 12 marzo 2008 11.52
A: sdl at lists.libsdl.org
Oggetto: Re: [SDL] R: Library idea to add effects such as blur to surfaces
Sorry if this is random rambling or something like this already
exists, but i’m
always using the gimp, and i keep tinking there is all that gpl’d code for
filters to modify bitmaps that it wouldnt be too much of a task to create a
library that can use some of that code to add effects to sdl surfaces for in
blur, outline, negative, erode things like that
i’m sure if done right this could be a useful addon libary for sdl.
Quoting Abderrahmane Madani <abderrahmane.madani at bncelettronica.com>:
What about ImageMagick?
i havnt looked at the source for imagemajic, but i am talking about a
effects that can be apllied to surfaces within the game to SDL surface, so for
example if something kills your main character you could have the original
image then have it blur to a blob when he dies, even if the effects are added
before (ie not live) this would mean that there is no need to create several
different images that need loaded, so if you were using this effect like this
and you decided your main character’s eyes suited a green jumper better than a
red one, you would only have to redisgn one image, then the code would create
the rest of the blurring death effect.
and effects like the neon outline effect in gimp would be great of elextrical
explosion type effects on stuff, and other uses, when i get a chance i’m gonna
have a look see if i can cope with the code in either imagmajick or gimp and
see how i would apply the effects to a sdl surface, it might be to much of a
headach for me, but i have a reasnoble understanding of what an sdl
just depend how and what these graphics programs use to deal with images.
SDL mailing list
SDL at lists.libsdl.org