PDA

View Full Version : Save screen as an image file



jos_t_tarigan
11-30-2008, 09:52 AM
Hi,

im currently trying to do a save screen as image file from my current OpenGL window. So its like when i press a button, the program save the current image in the OpenGL window as an image file. I currently able to do it manually, and save it as a TGA image. But I think other kind of file such as JPEG will be a hell of an algorithm to start from scratch. Is there any library so i can save the image to other type of image file such as JPEG?

Thanks in advance

trinitrotoluene
11-30-2008, 10:07 AM
There is JasPer (http://www.ece.uvic.ca/~mdadams/jasper/) and libjpeg (http://www.ijg.org/).

ZbuffeR
11-30-2008, 11:11 AM
And freeimage (http://freeimage.sourceforge.net/) for a bunch of formats.

_NK47
12-01-2008, 02:38 AM
DevIL aka OpenIL (http://openil.sourceforge.net/)