Unofficial OpenGL Software Development Kit: glimg::loaders::stb Namespace Reference

Unofficial OpenGL Software Development Kit 0.5.0

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- Namespace List
- Namespace Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Classes | Functions
glimg::loaders::stb Namespace Reference
Image Loaders

Contains the loader for PNG, JPEG, TGA, BMP, and GIF formats. More...

## Classes

class | StbLoaderException
| Base class for all exceptions thrown by the STB loaders. More...
class | UnableToLoadException
| Thrown when the STB loader could not load the image. More...

## Functions

ImageSet * | LoadFromFile (const std::string &filename)
| Loads a file from the disk, given an ASCII filename. More...
ImageSet * | LoadFromMemory (const unsigned char *buffer, size_t bufSize)
| As LoadFromFile, but from an already loaded buffer. The buffer pointer may be deleted after this call.

## Detailed Description

Contains the loader for PNG, JPEG, TGA, BMP, and GIF formats.

## Function Documentation

ImageSet* glimg::loaders::stb::LoadFromFile | ( | const std::string & | filename | ) |

Loads a file from the disk, given an ASCII filename.

This loader uses the public domain STB library to process the files. It therefore can load the following image formats:

- PNG
- JPEG (non-progressive)
- BMP
- TGA
- GIF

Exceptions

  StbLoaderException | Could not load the image. There are derived classes from this type that could be thrown.

Returns
  An ImageSet that represents the loaded image data.