C# XNA GIF animation: how to let another image animate?

Started by
1 comment, last by CC Ricers 9 years ago

hello!

i was adding something to my XNA project, and i downloaded the GIF animation library fromhttps://xnagif.codeplex.com/

i added the pipeline and references as needed (i followed the sample GIF animation) and one of my gif images worked (yay) but i have decided to add more gif images and only the first image loaded animates normally, while the other ones do not...i just see a still image/frame.

how am i supposed to fix that?

also just something extra, how can i make it so that i do not have specific color in the spritebatch.Draw parameters? i want the colors to remain as they are from image, but i cant find a way to get rid of the color restriction to be incolved as a parameter also. how can i get rid of that??

thanks in advance!

p.s. i have asked this question on else where and i have not gotten any responses from any websites. i really hope someone helps me here with this issue as my program is due very soon and wanna get this fixed!

thanks!

Advertisement

also just something extra, how can i make it so that i do not have specific color in the spritebatch.Draw parameters? i want the colors to remain as they are from image, but i cant find a way to get rid of the color restriction to be incolved as a parameter also. how can i get rid of that??

Just pass Color.White. Clearly mentioned in the MSDN documentation for SpriteBatch: https://msdn.microsoft.com/en-us/library/ff433986.aspx .

As for your other issues, it sounds like there is a bug in the XNAGIF library, or a problem with those particular GIFs.

If the GIFs need to be processed through a special pipeline with XNAGIF, you might want to double check that additional GIFs you add to the project have their correct content Importer and Processors set so they can work with the library. It might be causing the no animation issue with your other GIFs.

New game in progress: Project SeedWorld

My development blog: Electronic Meteor

This topic is closed to new replies.

Advertisement