PDA

View Full Version : Image Loading Library for loading image textures



jitendra2896
08-02-2017, 09:33 AM
Can you suggest a library that can decode PNG or JPG files. Also can you show me code sample as to how to load data into the texture object using glTexStorage2D() and glTextSubImage2D() by using the library. I'm much concerned with the parameters that I need to pass in these functions. I'm just looking for a consistent way to load images to the texture.

Silence
08-02-2017, 11:13 PM
Can you suggest a library that can decode PNG or JPG files.

There are many:

SOIL
DeviL
FreeImage
Gli...

They are well listed here (https://www.khronos.org/opengl/wiki/Image_Libraries).