Thursday, 19 May 2016

coordinate system - How to get CRS of a raster layer in pyqgis?


I have this problem accessing to the coordinate reference system(crs) of a raster layer map. I wonder if such thing is possible? I have used this xml from GDAL open map service to load in a raster layer(crs id 900913) to my stand-alone pyqgis application (http://www.gdal.org/frmt_wms_googlemaps_tms.xml) It displays the map just fine, but when I tried to draw an icon at a specific lat long position (crs id 4326), the icon appeared weirdly. I used the QgsCoordinateTransform class to convert the coordinates. Please advise me what I should do to get it right? I am very new to pyqgis. Thanks a ton!




No comments:

Post a Comment

arcpy - Changing output name when exporting data driven pages to JPG?

Is there a way to save the output JPG, changing the output file name to the page name, instead of page number? I mean changing the script fo...