Tuesday, March 30, 2010

loadMovie won't play animated gifs but...

I am using Flash CS3 with ActionScript 2.

My program so far succesfully can load into a movieClip (using loadMovie) external .jpg %26amp; .png %26amp; .gif (non-animated) and displays them properly. I can also have it load in an external .swf and get it to play properly. The only problem I have is with animated gifs... they load in but then only show the first frame/animation (even when using play() ).

Is there a different method besides play() to get a movie clip with an animated gif loaded into it to play?

This is only a sample, this is not the working code (it's very long so did not want to post it)... these are just the main calls that will work for the .swf file, so I thought they would work for the animated gif as well.

this.createEmptyMovieClip(''myMC'', 1);

myMC.loadMovie(''filename.gif'',1);

myMC.play();

Again, my 'real code' will load and display static .jpg .png or .gif files fine, as well it will load and play .swf files fine... it's just animated gifs that don't play.

My full code is here, if you want to look at it:

http://forums.adobe.com/thread/467815

Thanks

loadMovie won't play animated gifs but...

As far as I know, you cannot play an animated gif file in Flash.?Only the first image of it will display.

loadMovie won't play animated gifs but...

Thanks for the reply Ned Murphy... when you initially answered my first thought was ''that can't be right'', but a search for 'animated gif' in the Flash CS3 Help turns up multiple occurences of ''If you load an animated GIF, only the first frame is displayed.''

So I guess I don't have a problem to solve after all... just a feature request!!!

No comments:

Post a Comment