diff options
| author | Even Rouault <even.rouault@spatialys.com> | 2019-12-04 18:56:15 +0100 |
|---|---|---|
| committer | Even Rouault <even.rouault@spatialys.com> | 2019-12-06 21:35:14 +0100 |
| commit | 126384854bf8e1b7461aebcc28966a6559971de1 (patch) | |
| tree | 261e7125c6d9baa2b83d95b2b4547edf095b6850 /src/transformations/vgridshift.cpp | |
| parent | 41ff94791abfebaf8cf2c346b4aefb4895248bf3 (diff) | |
| download | PROJ-126384854bf8e1b7461aebcc28966a6559971de1.tar.gz PROJ-126384854bf8e1b7461aebcc28966a6559971de1.zip | |
vertical grid shift: rework to no longer load whole grid into memory
Diffstat (limited to 'src/transformations/vgridshift.cpp')
| -rw-r--r-- | src/transformations/vgridshift.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/transformations/vgridshift.cpp b/src/transformations/vgridshift.cpp index de0cdd8c..51f129ab 100644 --- a/src/transformations/vgridshift.cpp +++ b/src/transformations/vgridshift.cpp @@ -22,7 +22,7 @@ static PJ_XYZ forward_3d(PJ_LPZ lpz, PJ *P) { PJ_COORD point = {{0,0,0,0}}; point.lpz = lpz; - if (P->vgridlist_geoid != nullptr) { + if (!P->vgrids.empty()) { /* Only try the gridshift if at least one grid is loaded, * otherwise just pass the coordinate through unchanged. */ point.xyz.z += proj_vgrid_value(P, point.lp, Q->forward_multiplier); @@ -37,7 +37,7 @@ static PJ_LPZ reverse_3d(PJ_XYZ xyz, PJ *P) { PJ_COORD point = {{0,0,0,0}}; point.xyz = xyz; - if (P->vgridlist_geoid != nullptr) { + if (!P->vgrids.empty()) { /* Only try the gridshift if at least one grid is loaded, * otherwise just pass the coordinate through unchanged. */ point.xyz.z -= proj_vgrid_value(P, point.lp, Q->forward_multiplier); |
