Image Component Library (ICL)
Classes | Public Member Functions | Protected Attributes | List of all members
icl::utils::VisualizationDescription Class Reference

Abstract class for visualization tasks. More...

#include <VisualizationDescription.h>

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

Protected Attributes

std::vector< Partparts
 internal part list More...
 

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

◆ addPart() [1/2]

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

adds a given part

◆ addPart() [2/2]

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

adds a given part

◆ circle()

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

adds a circle (intnerally handeled as ellipse)

◆ clear()

void icl::utils::VisualizationDescription::clear ( )
inline

clears the list

◆ color() [1/2]

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

sets the current draw color (no alpha)

◆ color() [2/2]

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

sets the current draw color (with alpha)

◆ ellipse() [1/2]

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

add an ellipse

◆ ellipse() [2/2]

void icl::utils::VisualizationDescription::ellipse ( const Rect32f r)
inline

add an ellipse

◆ fill() [1/2]

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

sets the current fill color (no alpha)

◆ fill() [2/2]

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

sets the current fill color (with alpha)

◆ fontsize()

void icl::utils::VisualizationDescription::fontsize ( float  s)
inline

defines the font size to be used

◆ getParts()

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

returns the parts

◆ line() [1/2]

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

adds a line (intnerally represented by bounding rectangle)

◆ line() [2/2]

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

adds a line (intnerally represented by bounding rectangle)

◆ linewidth()

void icl::utils::VisualizationDescription::linewidth ( float  w)
inline

defines the linewidth

◆ operator+()

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

adds two descriptions

Internally the part-lists are just concatenated

◆ operator+=()

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

adds another visualization description

Internally the part-lists are just concatenated

◆ point()

void icl::utils::VisualizationDescription::point ( const Point32f p)
inline

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

◆ points() [1/3]

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

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

◆ points() [2/3]

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

adds points from given float vector

◆ points() [3/3]

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

adds points from given vector of Points

◆ pointsize()

void icl::utils::VisualizationDescription::pointsize ( float  s)
inline

defines the point size

◆ polygon() [1/3]

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

template based creation of a polygon

◆ polygon() [2/3]

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

adds polygon from given float vector

◆ polygon() [3/3]

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

adds polygon from given vector of Points

◆ rect() [1/2]

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

add a rectangle

◆ rect() [2/2]

void icl::utils::VisualizationDescription::rect ( const Rect32f r)
inline

add a rectangle

◆ sym() [1/2]

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

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

◆ sym() [2/2]

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

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

◆ text() [1/2]

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

adds text

note that the text must be single lined

◆ text() [2/2]

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

adds text

note that the text must be single lined

◆ textangle()

void icl::utils::VisualizationDescription::textangle ( float  angle)
inline

sets the vertical text mode

Member Data Documentation

◆ parts

std::vector<Part> icl::utils::VisualizationDescription::parts
protected

internal part list


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