[SDL] Scaling routines
niels at nwagenaar.demon.nl
Wed Feb 12 02:47:01 PST 2003
Hello fellow SDL users/developers,
this question was possibly anwsered many times but since I don't have access to the
internet (ie : webbrowser) I hope people can anwser this by e-mail.
Currently I have a buffer which is a SDL_Surface, I can nicely draw this to the screen. At
the moment I use the putpixel and getpixel "examples" from the SDL website to scale (upto
sizes of 4 times of the buffer surface) the buffer surface and display it (directly) to my
primary display surface. This works but it's definately *NOT* fast (even on fast machines)
since the calculations in the for loops are time consuming.
I think it's better and faster to use alternate code for scaling the buffer surface and
blitting it directly to my primary display surface. Does anybody have examples (preferable
with source) to do this and perhaps using MMX?
I hope people can help me with this question :)
More information about the SDL