Re: [gdal-dev] units=km not working
Hi, Because the units mean the units of the projected coordinates. An example: https://epsg.io/map#srs=3067-1149=295545.168414=6836388.322477=4=streets Here x and y are in meters: "+proj=utm +zone=35 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs +type=crs". By changing the the units into kilometers the x value would change into 295.545168414 any y into 6836.388322477 but that does not change the size of the Earth. -Jukka Rahkonen- Lähettäjä: gdal-dev Puolesta Wilco K via gdal-dev Lähetetty: tiistai 23. tammikuuta 2024 21.57 Vastaanottaja: gdal-dev@lists.osgeo.org Aihe: [gdal-dev] units=km not working Hi, why is units=km not working? gdaltransform -s_srs EPSG:4326 -t_srs "+proj=stere +lat_0=90 +lon_0=0 +lat_ts=60 +a=6378.14 +b=6356.75 +x_0=0 +y_0=0 +units=km" The following error is returned: ERROR 1: PROJ: proj_create_operations: Source and target ellipsoid do not belong to the same celestial body Converting +a and +b to meters and it does works: gdaltransform -s_srs EPSG:4326 -t_srs "+proj=stere +lat_0=90 +lon_0=0 +lat_ts=60 +a=6378140 +b=6356750 +x_0=0 +y_0=0" Any ideas? Wilco ___ gdal-dev mailing list gdal-dev@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/gdal-dev
Re: [gdal-dev] units=km not working
Le 23/01/2024 à 20:56, Wilco K via gdal-dev a écrit : Hi, why is *units=km* not working? * * *gdaltransform -s_srs EPSG:4326 -t_srs "+proj=stere +lat_0=90 +lon_0=0 +lat_ts=60 +a=6378.14 +b=6356.75 +x_0=0 +y_0=0 **+units=km" * The following error is returned: ERROR 1: PROJ: proj_create_operations: Source and target ellipsoid do not belong to the same celestial body Converting +a and +b to meters and it does works: *gdaltransform -s_srs EPSG:4326 -t_srs "+proj=stere +lat_0=90 +lon_0=0 +lat_ts=60 +a=6378140 +b=6356750 +x_0=0 +y_0=0"* Any ideas? Cf https://proj.org/en/9.3/usage/projections.html#units : "Horizontal coordinate system units can be specified using the |+units| keyword [...] Note that this does /not/ affect the units of linear parameters such as |+x_0| or |+y_0| which should always be specified in meters." . This also applies to the +a and +b parameters. Doc enhancement filed in https://github.com/OSGeo/PROJ/pull/4010 When you specify +units=km, it just means that you wish the output projected coordinates are expressed in km. But this doesn't affect the units of any linear parameters of the projection definition. Even -- http://www.spatialys.com My software is free, but my time generally not. ___ gdal-dev mailing list gdal-dev@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/gdal-dev
[gdal-dev] units=km not working
Hi, why is units=km not working? gdaltransform -s_srs EPSG:4326 -t_srs "+proj=stere +lat_0=90 +lon_0=0 +lat_ts=60 +a=6378.14 +b=6356.75 +x_0=0 +y_0=0 +units=km" The following error is returned: ERROR 1: PROJ: proj_create_operations: Source and target ellipsoid do not belong to the same celestial body Converting +a and +b to meters and it does works: gdaltransform -s_srs EPSG:4326 -t_srs "+proj=stere +lat_0=90 +lon_0=0 +lat_ts=60 +a=6378140 +b=6356750 +x_0=0 +y_0=0" Any ideas? Wilco ___ gdal-dev mailing list gdal-dev@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/gdal-dev