Hi, i tried it but it works only with point tranformation. I would llike to tranform the entire vector layer. Do you have any suggestions?
Thanks Francesco >----Messaggio originale---- >Da: rdmaili...@duif.net >Data: 14/12/2011 13.06 >A: "francescobocca...@libero.it"<francescobocca...@libero.it> >Cc: <qgis-developer@lists.osgeo.org> >Ogg: Re: [Qgis-developer] Trasform QgsVectorLayer proj4 to another > >On 2011-12-14 12:59, francescobocca...@libero.it wrote: >> Hi to all, >> i have a question for you. I have 2 vector layer that have two different >> spatial references. I'd like to tranform(convert) one of these in the same >> coordinate system. >> Like that: >> >> crsStart = QgsCoordinateReferenceSystem() >> crsStart.createFromProj4(layerA.crs().toProj4()) >> crsDest = QgsCoordinateReferenceSystem() >> crsDest.createFromProj4(layerB.crs().toProj4()) >> >> if crsStart != crsDest: >> >> layerA = QgsCoordinateTransform(crsStart,crsDest). >> transformLayerAtoLayerB > >Hi F, > >Have a look here: > >http://www.qgis.org/pyqgis-cookbook/index.html > >specially here: > >http://www.qgis.org/pyqgis-cookbook/crs.html#coordinate-reference-systems > >Hope this helps... > >Regards, > >Richard > _______________________________________________ Qgis-developer mailing list Qgis-developer@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/qgis-developer