[SDL] Animated GIFs

Philipp Lorenz descent1 at gmx.net
Thu Apr 5 00:53:53 PDT 2007


Yes, I had the same idea yesterday, but i am new with SDL! The compiler gave 
me:

d3launch.cpp:33: error: cannot convert ‘int’ to ‘SDL_Surface [9]’ in 
initialization
d3launch.cpp: In function ‘bool load_files()’:
d3launch.cpp:217: error: expected primary-expression before ‘]’ token
d3launch.cpp:134: error: too many arguments to function ‘SDL_Surface* 
load_image(std::string)’
d3launch.cpp:217: error: at this point in file
d3launch.cpp: In function ‘int main(int, char**)’:
d3launch.cpp:445: error: expected primary-expression before ‘]’ token

If you need the code, go to this link: 
http://intelcentino.in.funpic.de/upload/d3launch.cpp

Thanks,

P. Lorenz



> Hello !
>
> > I was creating an animated GIF-file and included it into my program. But
> > now
> > the GIF isn't animated.
> >
> > I have the pictures seperate!
> >
> > Who can help me?
>
> As Anim. GIFs need to be updated reguarly,
> your are on your own with them.
>
> I would split the Anim GIF into single BMPs
> or PNGs for example, then load them into an array
> and blit the bitmaps when necessary. The easiest is
> to do this in your main loop.
>
>
> CU
>
> _______________________________________________
> SDL mailing list
> SDL at lists.libsdl.org
> http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


More information about the SDL mailing list