Main Page | Class List | File List | Class Members

clip::parampic_of_< PEL > Class Template Reference

Supports parameter control through interaction on picture windows. More...

#include <picture.h>

List of all members.

Public Member Functions

 parampic_of_ (colour_picture_of_< PEL > *background, const double xstart, const double xend, const double xfirst, const double ystart, const double yend, const double yfirst, const char *name)
 parampic_of_ (const double xstart, const double xend, const double xfirst, const char *name)
 ~parampic_of_ ()
 Destructor.
int XY (double &xout, double &yout)
int X (double &xout)
int Y (double &yout)


Detailed Description

template<typename PEL>
class clip::parampic_of_< PEL >

Supports parameter control through interaction on picture windows.

parampic is a particular kind of colour_picture_of_ providing easy facilities for a programmer to display one- and two-dimensional sliders via CLIP. It can be supplied with a background picture, or use default ramps, then it displays a hairline slider over the background. The range of the slider is set during construction, and thereafter, a user clicking in the picture moves the slider to the appropriate scaled value. The program can then easily read off the current value of the parameter(s) represented by the parampic. It is assumed that the parameter read functions are called often when input is expected because sensing of pointer (mouse) state and updating are only done when the functions are called.


Constructor & Destructor Documentation

template<typename PEL>
clip::parampic_of_< PEL >::parampic_of_ colour_picture_of_< PEL > *  background,
const double  xstart,
const double  xend,
const double  xfirst,
const double  ystart,
const double  yend,
const double  yfirst,
const char *  name
[inline]
 

Create a parameter picture with the given background or a default if the background pointer argument = 0, with X,Y control ranges as specified. The X parameter value can vary between xstart and xend, with initial value xfirst; the Y parameter value can vary between ystart and yend, with initial value yfirst. If xstart == xend, the slider is 1D and vertical; if ystart == yend, the slider is 1D and horizontal. Otherwise, both X and Y can be varied.

template<typename PEL>
clip::parampic_of_< PEL >::parampic_of_ const double  xstart,
const double  xend,
const double  xfirst,
const char *  name
[inline]
 

Create the most common kind of parameter picture. 1D in X with default background.


Member Function Documentation

template<typename PEL>
int clip::parampic_of_< PEL >::X double &  xout  )  [inline]
 

Get current X value into xout. Returns 1 if there has been a change, 0 otherwise.

template<typename PEL>
int clip::parampic_of_< PEL >::XY double &  xout,
double &  yout
[inline]
 

Get current X and Y values into xout and yout. Returns 1 if there has been a change, 0 otherwise.

template<typename PEL>
int clip::parampic_of_< PEL >::Y double &  yout  )  [inline]
 

Get current Y value into yout. Returns 1 if there has been a change, 0 otherwise.


The documentation for this class was generated from the following file:
Generated on Sun Mar 13 20:59:22 2005 for clip by doxygen 1.3.8