PieDock  1.6.3
Static Public Member Functions | Static Protected Member Functions | List of all members
PieDock::Png Class Reference

#include <Png.h>

Static Public Member Functions

static ArgbSurfaceload (const std::string &)
 
static ArgbSurfaceload (std::istream &)
 
static void save (const std::string &, const ArgbSurface *)
 
static void save (std::ostream &, const ArgbSurface *)
 

Static Protected Member Functions

static void read (png_structp, png_bytep, png_size_t)
 
static void write (png_structp, png_bytep, png_size_t)
 
static void flush (png_structp)
 

Detailed Description

Load/Save a PNG file

Member Function Documentation

void Png::flush ( png_structp  png)
staticprotected

Flush data to disk

Parameters
png- png pointer

Referenced by save().

ArgbSurface * Png::load ( const std::string &  f)
static

Load image by path and filename

Parameters
f- path and filename of PNG to load

Referenced by PieDock::IconMap::getFillerIcon(), PieDock::IconMap::getIconByName(), PieDock::IconMap::getMissingIcon(), and PieDock::ActiveIndicator::load().

ArgbSurface * Png::load ( std::istream &  in)
static

Load image from a PNG input stream

Parameters
in- input stream

References read().

void Png::read ( png_structp  png,
png_bytep  data,
png_size_t  length 
)
staticprotected

Read png data from a stream

Parameters
png- png pointer
data- pointer to data
length- data length

Referenced by load().

void Png::save ( const std::string &  f,
const ArgbSurface s 
)
static

Save surface to given path and filename

Parameters
f- path and filename of PNG
s- surface to save

Referenced by PieDock::IconMap::saveIcon().

void Png::save ( std::ostream &  out,
const ArgbSurface s 
)
static

Save surface to output stream in PNG format

Parameters
out- output stream
s- surface to save

References flush(), and write().

void Png::write ( png_structp  png,
png_bytep  data,
png_size_t  length 
)
staticprotected

Write png data to a stream

Parameters
png- png pointer
data- pointer to data
length- data length

Referenced by save().


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