From ece151aed1b4bf2634de5759f37fd7bc005e8313 Mon Sep 17 00:00:00 2001 From: Even Rouault Date: Sat, 6 Jul 2019 17:06:23 +0200 Subject: CRS JSON: export GeographicCRS and Projected CRS --- test/cli/testprojinfo_out.dist | 74 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 74 insertions(+) (limited to 'test/cli') diff --git a/test/cli/testprojinfo_out.dist b/test/cli/testprojinfo_out.dist index f742fa60..20ae544a 100644 --- a/test/cli/testprojinfo_out.dist +++ b/test/cli/testprojinfo_out.dist @@ -135,6 +135,80 @@ WKT1_ESRI: GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.257223563]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]] +JSON: +{ + "type": "GeographicCRS", + "name": "WGS 84", + "datum": { + "type": "GeodeticReferenceFrame", + "name": "World Geodetic System 1984", + "ellipsoid": { + "type": "Ellipsoid", + "name": "WGS 84", + "semi_major_axis": { + "value": 6378137, + "unit": { + "type": "LinearUnit", + "name": "metre", + "conversion_factor": 1 + } + }, + "inverse_flattening": 298.257223563 + }, + "prime_meridian": { + "type": "PrimeMeridian", + "name": "Greenwich", + "longitude": { + "value": 0, + "unit": { + "type": "AngularUnit", + "name": "degree", + "conversion_factor": 0.0174532925199433 + } + } + } + }, + "coordinate_system": { + "type": "CoordinateSystem", + "subtype": "ellipsoidal", + "axis": [ + { + "type": "Axis", + "name": "Geodetic latitude", + "abbreviation": "Lat", + "direction": "north", + "unit": { + "type": "AngularUnit", + "name": "degree", + "conversion_factor": 0.0174532925199433 + } + }, + { + "type": "Axis", + "name": "Geodetic longitude", + "abbreviation": "Lon", + "direction": "east", + "unit": { + "type": "AngularUnit", + "name": "degree", + "conversion_factor": 0.0174532925199433 + } + } + ] + }, + "area": "World", + "bbox": { + "south_latitude": -90, + "west_longitude": -180, + "north_latitude": 90, + "east_longitude": 180 + }, + "id": { + "authority": "EPSG", + "code": 4326 + } +} + Testing projinfo -s EPSG:4326 -t EPSG:32631 Candidate operations found: 1 ------------------------------------- -- cgit v1.2.3 From ec49c9cd0aa9de24623920b8de226daf05a0e90f Mon Sep 17 00:00:00 2001 From: Even Rouault Date: Thu, 8 Aug 2019 19:18:26 +0200 Subject: projinfo: rename JSON to PROJJSON --- test/cli/testprojinfo_out.dist | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'test/cli') diff --git a/test/cli/testprojinfo_out.dist b/test/cli/testprojinfo_out.dist index 20ae544a..530a0426 100644 --- a/test/cli/testprojinfo_out.dist +++ b/test/cli/testprojinfo_out.dist @@ -135,7 +135,7 @@ WKT1_ESRI: GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.257223563]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]] -JSON: +PROJJSON: { "type": "GeographicCRS", "name": "WGS 84", -- cgit v1.2.3 From 89f2cc7ec4178a369e73e9cd115a2552a55d870a Mon Sep 17 00:00:00 2001 From: Even Rouault Date: Thu, 8 Aug 2019 20:04:20 +0200 Subject: PROJJSON export: use more compact form --- test/cli/testprojinfo_out.dist | 37 +++---------------------------------- 1 file changed, 3 insertions(+), 34 deletions(-) (limited to 'test/cli') diff --git a/test/cli/testprojinfo_out.dist b/test/cli/testprojinfo_out.dist index 530a0426..73751b99 100644 --- a/test/cli/testprojinfo_out.dist +++ b/test/cli/testprojinfo_out.dist @@ -143,56 +143,25 @@ PROJJSON: "type": "GeodeticReferenceFrame", "name": "World Geodetic System 1984", "ellipsoid": { - "type": "Ellipsoid", "name": "WGS 84", - "semi_major_axis": { - "value": 6378137, - "unit": { - "type": "LinearUnit", - "name": "metre", - "conversion_factor": 1 - } - }, + "semi_major_axis": 6378137, "inverse_flattening": 298.257223563 - }, - "prime_meridian": { - "type": "PrimeMeridian", - "name": "Greenwich", - "longitude": { - "value": 0, - "unit": { - "type": "AngularUnit", - "name": "degree", - "conversion_factor": 0.0174532925199433 - } - } } }, "coordinate_system": { - "type": "CoordinateSystem", "subtype": "ellipsoidal", "axis": [ { - "type": "Axis", "name": "Geodetic latitude", "abbreviation": "Lat", "direction": "north", - "unit": { - "type": "AngularUnit", - "name": "degree", - "conversion_factor": 0.0174532925199433 - } + "unit": "degree" }, { - "type": "Axis", "name": "Geodetic longitude", "abbreviation": "Lon", "direction": "east", - "unit": { - "type": "AngularUnit", - "name": "degree", - "conversion_factor": 0.0174532925199433 - } + "unit": "degree" } ] }, -- cgit v1.2.3 From cad1c5cf61fc00759bf4ad17b0b34f57f4945de6 Mon Sep 17 00:00:00 2001 From: Even Rouault Date: Sat, 17 Aug 2019 10:58:08 +0200 Subject: PROJJSON: rename file as projjson.schema.json, and add versionning to it and to exported PROJJSON strings --- test/cli/testprojinfo_out.dist | 1 + 1 file changed, 1 insertion(+) (limited to 'test/cli') diff --git a/test/cli/testprojinfo_out.dist b/test/cli/testprojinfo_out.dist index 73751b99..97c1138c 100644 --- a/test/cli/testprojinfo_out.dist +++ b/test/cli/testprojinfo_out.dist @@ -137,6 +137,7 @@ GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.25722 PROJJSON: { + "$schema": "https://proj.org/schemas/v0.1/projjson.schema.json", "type": "GeographicCRS", "name": "WGS 84", "datum": { -- cgit v1.2.3