Template Function navtk::utils::bilinear_interpolate
Defined in File interpolation.hpp
Function Documentation
-
template<typename Y>
Y navtk::utils::bilinear_interpolate(const Y &top_left, const Y &top_right, const Y &bottom_left, const Y &bottom_right, const Y &x_frac, const Y &y_frac) Perform bilinear interpolation between 4-corners.
- Parameters
top_left – Top-left corner(s).
top_right – Top-right corner(s).
bottom_left – Bottom-left corner(s).
bottom_right – Bottom-right corner(s).
x_frac – Offset(s) from the top left corner in the x-direction as a percentage of the distance between top left and top right corners.
y_frac – Offset(s) from the top left corner in the x-direction as a percentage of the distance between top left and bottom left corners.
- Returns
Interpolated value(s).