PDA

View Full Version : JPEG, PNG, TIFF



ramana
10-15-2003, 09:04 PM
Is it possible to display the .JPEG, .PNG and .TIFF images in the OpenGL rendering context? If possible, from where i can download the info.

PanzerSchreck
10-15-2003, 11:49 PM
Either use a lib that supports your file formats (TIFF isn't supported widely due to some technical limitations of that format) or grab the file format's specs at http://www.wotsit.org and load them by yourself.

mdog1234
10-16-2003, 08:30 PM
Yes its possible but from experience I have found jpegs to be more of a hassle then anything. First of all the file is read in reverse so every other texture format will look right but if you draw your jpeg with out reversing you texture coords, the image will be upside down. Plus its a lossy format. I personally prefer tga's. They can get big at times but there are ways to compress them.

Radish
10-16-2003, 08:37 PM
Targa is fun to say, too. Targa targa!

DJSnow
10-16-2003, 09:56 PM
use DevIL, at sourceforge, to load various images; in the most cases it works without problems, but there are some non-pursuable bugs with some images from time to time...

[This message has been edited by DJSnow (edited 10-16-2003).]

nukem
10-18-2003, 08:58 PM
There are many tutorials and code to load TGA and jpg files. They are commonly used in games. For jpg files I would suggest using libjpg TGA files you can create your own function for. google it/search the fourms here.