Skip to content
Snippets Groups Projects
Unverified Commit ccac28fb authored by Giovanni's avatar Giovanni Committed by GitHub
Browse files

Merge pull request #379 from ves-code/ves-interpolation-fix

Fix for bug in TD_GRID
parents 0dd1e0ca b4b9f073
No related branches found
No related tags found
No related merge requests found
......@@ -193,3 +193,8 @@ For developers:
- `LDSHARED` is now correctly taken into account when launching `./configure`.
- Fixed installation with `--disable-shared`.
- Cppcheck upgraded to 1.84.
## Version 2.4.3 (to be released)
For users:
- Module VES: Fixed a bug in TD_GRID for 2D grids where the grid spacing is not the same for both dimensions.
......@@ -68,8 +68,8 @@ double GridLinearInterpolation::getGridValueWithLinearInterpolation_2D(Grid* gri
i00[0] = i01[0] = unsigned( std::floor( (arg[0]-grid_min[0])/grid_delta[0] ) );
i10[0] = i11[0] = unsigned( std::ceil( (arg[0]-grid_min[0])/grid_delta[0] ) );
i00[1] = i10[1] = unsigned( std::floor( (arg[1]-grid_min[1])/grid_delta[0] ) );
i01[1] = i11[1] = unsigned( std::ceil( (arg[1]-grid_min[1])/grid_delta[0] ) );
i00[1] = i10[1] = unsigned( std::floor( (arg[1]-grid_min[1])/grid_delta[1] ) );
i01[1] = i11[1] = unsigned( std::ceil( (arg[1]-grid_min[1])/grid_delta[1] ) );
// https://en.wikipedia.org/wiki/Bilinear_interpolation
double x = arg[0];
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment