Sign in to follow this  
carlsfinch

Does Allegro support .png, or .jpg if not how come?

Recommended Posts

"Allegro is a free, cross-platform video game programming library, providing functions for drawing, text output, sound and others. It even has some (limited) 3D graphics support, which can be extended by using AllegroGL though. Several additional support libraries have been provided by the community, adding support for various file formats as well. As a consequence, Allegro includes full support for PNG, JPG, GIF and other graphical formats, along with MIDI, WAV and MOD sound support. Allegro also includes limited support for GUI elements, also extended by a number of libraries."

So yes, it does support those formats.

Share this post


Link to post
Share on other sites
Allegro natively supports BMP and three lesser used formats. It doesn't support other formats because of license concerns or feature bloat. It does, however, provide a universal hook for loading any type of image.

For PNG, you need to use libPNG and the loadPNG wrapper.

For JPEG, you need to use JPGAlleg

Once you install those two, you can load_bitmap() on PNGs and JPEGs.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this