#include <mc_trajectory/LinearInterpolation.h>
|
T | operator() (const T &v1, const T &v2, double t) const |
| Linear interpolation between two values. More...
|
|
◆ operator()()
Linear interpolation between two values.
\[ f(t) = (1 - t) * v_1 + t * v_2; \]
- Template Parameters
-
T | value type, must support multiplication with scalar and addition with T |
- Parameters
-
v1 | First value |
v2 | Second value |
t | Interpolation ratio between 0 and 1 |
- Returns
- v1 for t = 0
- v2 for t = 1
- value linearly interpolated between v1 and v2 otherwise
The documentation for this struct was generated from the following file: