16 #ifndef INTERPOLATION_H
17 #define INTERPOLATION_H
19 #include <pointing/transferfunctions/TransferFunction.h>
23 #include <pointing/utils/ConfigDict.h>
27 enum class InterpolationSpace { VelocityGain, VelocityVelocity };
36 void constructAccMap();
37 void loadTableFromConfig(ConfigDict &accCfg);
38 void loadFromDirectory();
47 InterpolationSpace space = InterpolationSpace::VelocityGain;
49 bool normalize =
false;
50 std::string directory;
53 int previousMouseRawX;
54 int previousMouseRawY;
55 float previousMouseXRemainder;
56 float previousMouseYRemainder;
64 void Interpolate(std::vector<int> &lowInd, std::vector<int> &highInd);
69 void TableToCoefficients();
74 std::map<std::string, std::string> mapAcc;
75 std::string replaceAlias(std::string &curAcc);
77 std::vector<float> tableAcc;
78 float valueFromTable(
unsigned index);
85 double valueFromTable(
double index);
92 void loadTableStr(std::string tableData);
96 void applyi(
int dxMickey,
int dyMickey,
int *dxPixel,
int *dyPixel,
97 TimeStamp::inttime timestamp=TimeStamp::undef);
99 void applyd(
int dxMickey,
int dyMickey,
double *dxPixel,
double *dyPixel,
100 TimeStamp::inttime timestamp=TimeStamp::undef);
102 URI
getURI(
bool expanded=
false)
const;
106 #endif // INTERPOLATION_H
void clearState(void)
Method which clears the current state of the device to be the default one (without any remainders or ...
Definition: Interpolation.cpp:204
The Interpolation class is subclass of TransferFunction which can interpolate between given values in...
Definition: Interpolation.h:34
void applyi(int dxMickey, int dyMickey, int *dxPixel, int *dyPixel, TimeStamp::inttime timestamp=TimeStamp::undef)
apply The main method of the class which applies the transfer function.
Definition: Interpolation.cpp:237
void Interpolate(std::vector< int > &lowInd, std::vector< int > &highInd)
Interpolate Values that do not exist in the main table are interpolated using 2 other tables which re...
Definition: Interpolation.cpp:52
The PointingDevice class is used to represent Pointing Devices connected to the computer or pseudo-de...
Definition: PointingDevice.h:36
DisplayDevice class is used to represent the displays connected to the computer.
Definition: DisplayDevice.h:31
The TransferFunction class is an abstract class that creates an object of its concrete subclasses...
Definition: TransferFunction.h:38
URI getURI(bool expanded=false) const
getURI The method constructs URI corresponding to the type and parameters of the transfer function...
Definition: Interpolation.cpp:297
void applyd(int dxMickey, int dyMickey, double *dxPixel, double *dyPixel, TimeStamp::inttime timestamp=TimeStamp::undef)
apply The main method of the class which applies the transfer function.
Definition: Interpolation.cpp:274