summary refs log tree commit diff
path: root/src/Math/Interpolation.hpp
blob: eaaa67d2389537e6cfee863f68bbcd172aaf073c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
#pragma once

#include "Common.hpp"
#include "Grid.hpp"

namespace Math {

float linear_interpolation(Vector<2> val, float left, float right, float pos);
float bilinear_interpolation(Matrix<2, 2> val, GridCellBoundaries cell, Vector<2> pos);
float trilinear_interpolation(Matrix<2, 2> val_front, Matrix<2, 2> val_back, const CubeCellBoundaries& cell, Vector<3> pos);

}