Skip to content

Commit

Permalink
process properly EPSG_CODE_METHOD_VERTICALGRID_GTG with code 1129
Browse files Browse the repository at this point in the history
  • Loading branch information
jjimenezshaw committed Aug 1, 2024
1 parent 6400b75 commit 5d173d8
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/iso19111/operation/singleoperation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2269,6 +2269,7 @@ static bool isRegularVerticalGridMethod(int methodEPSGCode,
return methodEPSGCode == EPSG_CODE_METHOD_VERTICALGRID_NZLVD ||
methodEPSGCode == EPSG_CODE_METHOD_VERTICALGRID_BEV_AT ||
methodEPSGCode == EPSG_CODE_METHOD_VERTICALGRID_GTX ||
methodEPSGCode == EPSG_CODE_METHOD_VERTICALGRID_GTG ||
methodEPSGCode == EPSG_CODE_METHOD_VERTICALGRID_PL_TXT;
}

Expand Down
4 changes: 4 additions & 0 deletions src/proj_constants.h
Original file line number Diff line number Diff line change
Expand Up @@ -656,6 +656,10 @@
#define EPSG_NAME_METHOD_VERTICALGRID_GTX \
"Vertical Offset by Grid Interpolation (gtx)"

#define EPSG_CODE_METHOD_VERTICALGRID_GTG 1129
#define EPSG_NAME_METHOD_VERTICALGRID_GTG \
"Vertical Offset by Grid Interpolation (gtg)"

#define EPSG_CODE_METHOD_VERTICALGRID_PL_TXT 1101
#define EPSG_NAME_METHOD_VERTICALGRID_PL_TXT \
"Vertical Offset by Grid Interpolation (PL txt)"
Expand Down
9 changes: 9 additions & 0 deletions test/unit/test_factory.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1208,6 +1208,15 @@ TEST(factory, AuthorityFactory_affine_parametric_transform) {

// ---------------------------------------------------------------------------

TEST(factory, AuthorityFactory_10566_issue_4212) {
auto factory = AuthorityFactory::create(DatabaseContext::create(), "EPSG");
auto op = factory->createCoordinateOperation("10566", true);
EXPECT_EQ(op->exportToPROJString(PROJStringFormatter::create().get()),
"+proj=vgridshift +grids=dk_sdfi_gllmsl_2022.tif +multiplier=1");
}

// ---------------------------------------------------------------------------

TEST(factory,
AuthorityFactory_createCoordinateOperation_concatenated_operation) {
auto factory = AuthorityFactory::create(DatabaseContext::create(), "EPSG");
Expand Down

0 comments on commit 5d173d8

Please sign in to comment.