MorphoGraphX
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Classes | Public Member Functions | List of all members
mgx::util::Function Class Reference

A utility class for functions. More...

#include <Function.hpp>

Public Member Functions

 Function (std::string filename)
 
 Function (const Function &copy)
 
Functionoperator= (const Function &)
 
double operator() (double x)
 
const Vector< 2, double > & getMax () const
 
const Vector< 2, double > & getMin () const
 
void reread ()
 
void setSamples (size_t n)
 
bool error ()
 
void scaleX (double s)
 Scale the x axis by s. More...
 
void scaleY (double s)
 Scale the y axis by s. More...
 
double scaleX () const
 Get the current x scaling.
 
double scaleY () const
 Get the current y scaling.
 
void shiftX (double s)
 Shift the x axis by s. More...
 
void shiftY (double s)
 Shift the y axis by s. More...
 
double shiftX () const
 Get the current x axis shift.
 
double shiftY () const
 Get the current y axis shift.
 
void normalizeY (bool shift=true)
 
void normalizeX (bool shift=true)
 

Detailed Description

A utility class for functions.

This class is a function object that encapsulates functions in the VLAB function formats (original and fver 1 1).

Member Function Documentation

void mgx::util::Function::scaleX ( double  s)
inline

Scale the x axis by s.

Parameters
sScaling factor to apply to the axis
void mgx::util::Function::scaleY ( double  s)
inline

Scale the y axis by s.

Parameters
sScaling factor to apply to the axis
void mgx::util::Function::shiftX ( double  s)
inline

Shift the x axis by s.

Parameters
sShift of the axis

Note that the shift happens after the scaling, so it should be written in the scaled reference system.

void mgx::util::Function::shiftY ( double  s)
inline

Shift the y axis by s.

Parameters
sShift of the axis

Note that the shift happens after the scaling, so it should be written in the scaled reference system.


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