Jump to content
  • Advertisement
Sign in to follow this  
Angelic Ice

C++: Merging PNGs and GIFs

This topic is 607 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello : )

 

I want to create a process that inserts PNG #2 into PNG #1. Potentially convert a GIF to PNG or convert an animated GIF to a PNG (each frame next to each other).

Are there any slick libraries or ways that would help me handle this?

Additionally, resize PNGs.

 

Image sizes could go up to 8192x8192 etc. (depends on GPU).

It should be highly cross-platform (Android, Windows, iOS and Linuxs).

 

Magick++ seems a bit too much, as I do not even need most of the features.

 

Thanks for your time : )

 

Share this post


Link to post
Share on other sites
Advertisement

Thanks, sadly DevIL is using LPGL - a license that seems to be a bit meh about static compiling. But thanks, I will put it into consideration!

 

Is it a requirement that your conversion tool use the GPU for some reason?

 

No : ) Just mentioned "depends on GPU", as the final product will be buffered by the GPU. The creation process must not happen on the GPU at all.

Edited by Angelic Ice

Share this post


Link to post
Share on other sites

I'd just use a PNG library and a GIF library to load and save the images.

From there, it's just copying pixels between images (for every row do for every coloumn do destpixel = srcpixel), hardly worth trying to find a library for that.

 

If you don't mind switching to Python, python + pillow will do the job too. It comes with a wide range of tools and modules (Pillow is a "friendly fork", taking over maintenance and development of PIL), and seems to understand GIFs, PNGs, and animation sequences.

http://effbot.org/imagingbook/

Edited by Alberth

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!