Image Component Library (ICL)
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Classes | Public Member Functions | Protected Attributes
icl::utils::VisualizationDescription Class Reference

Abstract class for visualization tasks. More...

#include <VisualizationDescription.h>

List of all members.

Classes

struct  Color
 Utility Color class. More...
struct  Part
 Single part of the the visualization pipeline. More...
struct  Text
 Utility class for Text. More...

Public Member Functions

const std::vector< Part > & getParts () const
 returns the parts
void clear ()
 clears the list
void addPart (const Part &part)
 adds a given part
void addPart (char c, const Any &content)
 adds a given part
VisualizationDescriptionoperator+= (const VisualizationDescription &other)
 adds another visualization description
VisualizationDescription operator+ (const VisualizationDescription &other)
 adds two descriptions
void color (icl8u r, icl8u g, icl8u b)
 sets the current draw color (no alpha)
void color (icl8u r, icl8u g, icl8u b, icl8u a)
 sets the current draw color (with alpha)
void fill (icl8u r, icl8u g, icl8u b)
 sets the current fill color (no alpha)
void fill (icl8u r, icl8u g, icl8u b, icl8u a)
 sets the current fill color (with alpha)
void rect (icl32f x, icl32f y, icl32f width, icl32f height)
 add a rectangle
void rect (const Rect32f &r)
 add a rectangle
void ellipse (icl32f x, icl32f y, icl32f width, icl32f height)
 add an ellipse
void ellipse (const Rect32f &r)
 add an ellipse
void circle (icl32f cx, icl32f cy, icl32f radius)
 adds a circle (intnerally handeled as ellipse)
void line (icl32f x1, icl32f y1, icl32f x2, icl32f y2)
 adds a line (intnerally represented by bounding rectangle)
void line (const Point32f &a, const Point32f &b)
 adds a line (intnerally represented by bounding rectangle)
void sym (char type, icl32f x, icl32f y)
 adds a symbol (supported types are +*x and .)
void sym (char type, const Point32f &p)
 adds a symbol (supported types are +*x and .)
void text (icl32f x, icl32f y, const std::string &text)
 adds text
void text (const Point32f &pos, const std::string &text)
 adds text
void point (const Point32f &p)
 adds a point (internally handles as a sym of type '.')
template<class Iterator >
void points (Iterator begin, Iterator end)
 adds points (data is in order [x1,y1,x2,y2]
void points (const std::vector< Point32f > &ps)
 adds points from given float vector
void points (const std::vector< Point > &ps)
 adds points from given vector of Points
template<class Iterator >
void polygon (Iterator begin, Iterator end)
 template based creation of a polygon
void polygon (const std::vector< Point32f > &ps)
 adds polygon from given float vector
void polygon (const std::vector< Point > &ps)
 adds polygon from given vector of Points
void linewidth (float w)
 defines the linewidth
void pointsize (float s)
 defines the point size

Protected Attributes

std::vector< Partparts
 internal part list

Detailed Description

Abstract class for visualization tasks.

The visualization class provides an interface for tools to provide visualization information. It's idea is to provide an easy interface -- it's implementation is rather slow, but completely neglegible for most applications;

Right now, this is a very simple interface which still needs to be extended

Supported Parts

Right now, the following parts are supported. Color and Fill parts remain active untill the next color/fill part is put into the list


Member Function Documentation

void icl::utils::VisualizationDescription::addPart ( const Part part) [inline]

adds a given part

void icl::utils::VisualizationDescription::addPart ( char  c,
const Any content 
) [inline]

adds a given part

void icl::utils::VisualizationDescription::circle ( icl32f  cx,
icl32f  cy,
icl32f  radius 
) [inline]

adds a circle (intnerally handeled as ellipse)

clears the list

void icl::utils::VisualizationDescription::color ( icl8u  r,
icl8u  g,
icl8u  b 
) [inline]

sets the current draw color (no alpha)

void icl::utils::VisualizationDescription::color ( icl8u  r,
icl8u  g,
icl8u  b,
icl8u  a 
) [inline]

sets the current draw color (with alpha)

void icl::utils::VisualizationDescription::ellipse ( icl32f  x,
icl32f  y,
icl32f  width,
icl32f  height 
) [inline]

add an ellipse

add an ellipse

void icl::utils::VisualizationDescription::fill ( icl8u  r,
icl8u  g,
icl8u  b 
) [inline]

sets the current fill color (no alpha)

void icl::utils::VisualizationDescription::fill ( icl8u  r,
icl8u  g,
icl8u  b,
icl8u  a 
) [inline]

sets the current fill color (with alpha)

const std::vector<Part>& icl::utils::VisualizationDescription::getParts ( ) const [inline]

returns the parts

void icl::utils::VisualizationDescription::line ( icl32f  x1,
icl32f  y1,
icl32f  x2,
icl32f  y2 
) [inline]

adds a line (intnerally represented by bounding rectangle)

void icl::utils::VisualizationDescription::line ( const Point32f a,
const Point32f b 
) [inline]

adds a line (intnerally represented by bounding rectangle)

defines the linewidth

VisualizationDescription icl::utils::VisualizationDescription::operator+ ( const VisualizationDescription other) [inline]

adds two descriptions

Internally the part-lists are just concatenated

VisualizationDescription& icl::utils::VisualizationDescription::operator+= ( const VisualizationDescription other) [inline]

adds another visualization description

Internally the part-lists are just concatenated

adds a point (internally handles as a sym of type '.')

template<class Iterator >
void icl::utils::VisualizationDescription::points ( Iterator  begin,
Iterator  end 
) [inline]

adds points (data is in order [x1,y1,x2,y2]

void icl::utils::VisualizationDescription::points ( const std::vector< Point32f > &  ps) [inline]

adds points from given float vector

void icl::utils::VisualizationDescription::points ( const std::vector< Point > &  ps) [inline]

adds points from given vector of Points

defines the point size

template<class Iterator >
void icl::utils::VisualizationDescription::polygon ( Iterator  begin,
Iterator  end 
) [inline]

template based creation of a polygon

void icl::utils::VisualizationDescription::polygon ( const std::vector< Point32f > &  ps) [inline]

adds polygon from given float vector

void icl::utils::VisualizationDescription::polygon ( const std::vector< Point > &  ps) [inline]

adds polygon from given vector of Points

void icl::utils::VisualizationDescription::rect ( icl32f  x,
icl32f  y,
icl32f  width,
icl32f  height 
) [inline]

add a rectangle

add a rectangle

void icl::utils::VisualizationDescription::sym ( char  type,
icl32f  x,
icl32f  y 
) [inline]

adds a symbol (supported types are +*x and .)

void icl::utils::VisualizationDescription::sym ( char  type,
const Point32f p 
) [inline]

adds a symbol (supported types are +*x and .)

void icl::utils::VisualizationDescription::text ( icl32f  x,
icl32f  y,
const std::string &  text 
) [inline]

adds text

note that the text must be single lined

void icl::utils::VisualizationDescription::text ( const Point32f pos,
const std::string &  text 
) [inline]

adds text

note that the text must be single lined


Member Data Documentation

internal part list


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines