SomeName::ImageArgs Class Reference

#include <ImageArgs.h>

Inheritance diagram for SomeName::ImageArgs:

SomeName::Root List of all members.

Detailed Description

A tiny service class that stores image and pixel-filtering information.

Instances of this class are often used as literal arguments to Image-related methods. See Image::Image and Glyph::writeImage for examples.

This class has public setters - permissive.


Public Member Functions

 ImageArgs (uint8_t magnification=1, uint16_t threshold=0, uint16_t quantize=0, uint8_t filter=0, uint8_t dustsize=0)
uint8_t magnification () const
uint16_t threshold () const
uint16_t quantize () const
uint8_t filter () const
uint8_t dustsize () const
uint8_t & magnification ()
uint16_t & threshold ()
uint16_t & quantize ()
uint8_t & filter ()
uint8_t & dustsize ()
uint16_t apply (const Image *image, const Coord &pos) const

Static Public Attributes

static const uint16_t MaxVal = 255
static const uint16_t MinVal = 0


Constructor & Destructor Documentation

SomeName::ImageArgs::ImageArgs uint8_t  magnification = 1,
uint16_t  threshold = 0,
uint16_t  quantize = 0,
uint8_t  filter = 0,
uint8_t  dustsize = 0
 

Constructor (in default mode, provides an ImageArgs that does no pixel modification).


Member Function Documentation

uint16_t SomeName::ImageArgs::apply const Image image,
const Coord pos
const
 

Given an image and position, returns a new color value for that pixel position based on the values of fields.

Note that the order in which the operations is performed significantly affects results. The order is always: filter, quantize, threshold, dustsize.


The documentation for this class was generated from the following files:
Generated on Thu Jun 8 11:53:14 2006 for SomeName by  doxygen 1.4.6