Image provider that can load JPEG (.jpg) files. More...

#include <jpeg_provider.h>

Static Public Member Functions

static PixelBuffer load (const std::string &filename, const FileSystem &fs, bool srgb=false)
 Called to load an image with this provider type. More...
 
static PixelBuffer load (const std::string &fullname, bool srgb=false)
 
static PixelBuffer load (IODevice &file, bool srgb=false)
 
static void save (PixelBuffer buffer, const std::string &filename, FileSystem &fs, int quality=85)
 Save the given PixelBuffer into a JPEG. More...
 
static void save (PixelBuffer buffer, const std::string &fullname, int quality=85)
 
static void save (PixelBuffer buffer, IODevice &file, int quality=85)
 

Detailed Description

Image provider that can load JPEG (.jpg) files.

Member Function Documentation

static PixelBuffer clan::JPEGProvider::load ( const std::string filename,
const FileSystem fs,
bool  srgb = false 
)
static

Called to load an image with this provider type.

Parameters
filenameName of the file to load.
directoryDirectory that file name is relative to.
static PixelBuffer clan::JPEGProvider::load ( const std::string fullname,
bool  srgb = false 
)
static
static PixelBuffer clan::JPEGProvider::load ( IODevice file,
bool  srgb = false 
)
static
static void clan::JPEGProvider::save ( PixelBuffer  buffer,
const std::string filename,
FileSystem fs,
int  quality = 85 
)
static

Save the given PixelBuffer into a JPEG.

Parameters
bufferThe PixelBuffer to save, format doesn't matter its converted if needed
filenameFile name of JPEG.
directoryDirectory that the file name is relative to.
qualityThe quality level of the JPEG (0-100), 100 being best quality.
static void clan::JPEGProvider::save ( PixelBuffer  buffer,
const std::string fullname,
int  quality = 85 
)
static
static void clan::JPEGProvider::save ( PixelBuffer  buffer,
IODevice file,
int  quality = 85 
)
static

The documentation for this class was generated from the following file: