wrapper class for using 'gd' graphics library
More...
#include <Image.hpp>
List of all members.
Classes |
struct | Color |
| struct for holding rgb values (in [0,255]) More...
|
struct | Point |
| struct for holding pixel coordinates More...
|
Public Member Functions |
virtual void | pixel (const Point &point, const Color &color)=0 |
| draw pixel
|
virtual void | string (const std::string &text, const Point &point, const Color &color, Size size=Large, int align=Left|Top)=0 |
| draw string
|
virtual void | stringUp (const std::string &text, const Point &point, const Color &color, Size size=Large, int align=Left|Top)=0 |
| draw string
|
virtual void | rectangle (const Point &point1, const Point &point2, const Color &color, bool filled=true)=0 |
| draw rectangle
|
virtual void | circle (const Point ¢er, int radius, const Color &color, bool filled=true)=0 |
| draw circle
|
virtual void | line (const Point &point1, const Point &point2, const Color &color)=0 |
| draw line
|
virtual void | clip (const Point &point1, const Point &point2)=0 |
| set clipping rectangle
|
virtual bool | writePng (const char *filename) const =0 |
| write png file
|
virtual | ~Image () |
Static Public Member Functions |
static Color | white () |
static Color | black () |
static std::auto_ptr< Image > | create (int logical_width, int logical_height, int output_width=-1, int output_height=-1) |
| create an instance optional output_width and output_height allows easy scaling to a desired output image size without complicating the drawing code (default is to use logical width and height)
|
Detailed Description
wrapper class for using 'gd' graphics library
Definition at line 38 of file Image.hpp.
Constructor & Destructor Documentation
virtual pwiz::util::Image::~Image |
( |
| ) |
|
|
inlinevirtual |
Member Function Documentation
static Color pwiz::util::Image::white |
( |
| ) |
|
|
inlinestatic |
Definition at line 52 of file Image.hpp.
{return Color(255, 255, 255);}
static Color pwiz::util::Image::black |
( |
| ) |
|
|
inlinestatic |
static std::auto_ptr<Image> pwiz::util::Image::create |
( |
int |
logical_width, |
|
|
int |
logical_height, |
|
|
int |
output_width = -1 , |
|
|
int |
output_height = -1 |
|
) |
| |
|
static |
create an instance optional output_width and output_height allows easy scaling to a desired output image size without complicating the drawing code (default is to use logical width and height)
virtual void pwiz::util::Image::pixel |
( |
const Point & |
point, |
|
|
const Color & |
color |
|
) |
| |
|
pure virtual |
virtual void pwiz::util::Image::string |
( |
const std::string & |
text, |
|
|
const Point & |
point, |
|
|
const Color & |
color, |
|
|
Size |
size = Large , |
|
|
int |
align = Left|Top |
|
) |
| |
|
pure virtual |
virtual void pwiz::util::Image::stringUp |
( |
const std::string & |
text, |
|
|
const Point & |
point, |
|
|
const Color & |
color, |
|
|
Size |
size = Large , |
|
|
int |
align = Left|Top |
|
) |
| |
|
pure virtual |
virtual void pwiz::util::Image::rectangle |
( |
const Point & |
point1, |
|
|
const Point & |
point2, |
|
|
const Color & |
color, |
|
|
bool |
filled = true |
|
) |
| |
|
pure virtual |
virtual void pwiz::util::Image::circle |
( |
const Point & |
center, |
|
|
int |
radius, |
|
|
const Color & |
color, |
|
|
bool |
filled = true |
|
) |
| |
|
pure virtual |
virtual void pwiz::util::Image::line |
( |
const Point & |
point1, |
|
|
const Point & |
point2, |
|
|
const Color & |
color |
|
) |
| |
|
pure virtual |
virtual void pwiz::util::Image::clip |
( |
const Point & |
point1, |
|
|
const Point & |
point2 |
|
) |
| |
|
pure virtual |
virtual bool pwiz::util::Image::writePng |
( |
const char * |
filename | ) |
const |
|
pure virtual |
The documentation for this class was generated from the following file:
- /Users/parag/_Research/pwiz/svn/trunk/pwiz/pwiz/utility/misc/Image.hpp