<html><head><style type='text/css'>p { margin: 0; }</style></head><body><div style='font-family: Arial; font-size: 12pt; color: #000000'>Hello,<br><br>Thanks for the answer. <br>The process works but I find an error of about 50m.<br>I take time to study it and I tell you.<br><br>Regards<br><br>Michel Bouillot<br><br>----- Mail Original -----<br>De: "Juan Lucas Dominguez Rubio" &lt;jldominguez@prodevelop.es&gt;<br>À: "Users and Developers mailing list" &lt;gvsig_internacional@listserv.gva.es&gt;, "Users and Developers mailing list" &lt;gvsig_internacional@listserv.gva.es&gt;<br>Envoyé: Vendredi 16 Juillet 2010 10:04:27<br>Objet: Re: [Gvsig_english] trouble with EPSG 2154 and 27561<br><br>

<style>p { margin: 0; }</style>


<div id="idOWAReplyText96857">
<div><font color="#000000" face="Times New Roman" size="3">Hello, Michel:</font></div>
<div>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3">I think there's some confusion about the meaning of the EPSG codes. According to spatialref.org, the PRJ file for EPSG:27561 is this:</font></div>
<div>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3"><a href="http://spatialreference.org/ref/epsg/27561/prj/" target="_blank">http://spatialreference.org/ref/epsg/27561/prj/</a></font></div>
<div>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3">But that file is not like the one that comes with your shapefile.</font></div>
<div>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3">gvSIG is probably using the definition found in the spatialref.org website, so that's why your shapefiles do not match if you select EPSG:27561 when adding that file to your view.</font></div>
<div>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3">According to spatialref.org, the CRS that matches your PRJ file is 'NTF Lambert Zone 1 France 2SP' (code SR-ORG:6910):</font></div>
<div>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3"><a href="http://spatialreference.org/ref/sr-org/6910/prj/" target="_blank">http://spatialreference.org/ref/sr-org/6910/prj/</a></font></div>
<div>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3">So all you have to do is declare it as a user-defined CRS in gvSIG.</font></div>
<div>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3">This has worked for me (I'll refer to your files as montreuil_2154.shp and montreuil_27561.shp):</font></div>
<div>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3">- from the project manager, click 'New' to create a new view. Select it (without opening it) and click on 'Properties'</font></div>
<div><font color="#000000" face="Times New Roman" size="3">- clic on the [...] button to change the view's CRS</font></div>
<div><font color="#000000" face="Times New Roman" size="3">- choose 'Type: user CRS' and click on 'New'</font></div>
<div><font color="#000000" face="Times New Roman" size="3">- choose the 'From WKT' option and paste this paragraph in the text box:</font></div>
<div>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3">PROJCS["unnamed",GEOGCS["unnamed ellipse",DATUM["unknown",SPHEROID["unnamed",6378249.2,293.4660200000053],TOWGS84[-168,-60,320,0,0,0,0]],PRIMEM["Greenwich",0],UNIT["degree",0.0174532925199433]],PROJECTION["Lambert_Conformal_Conic_2SP"],PARAMETER["standard_parallel_1",48.5985227778],PARAMETER["standard_parallel_2",50.3959116667],PARAMETER["latitude_of_origin",49.5],PARAMETER["central_meridian",2.3372291667],PARAMETER["false_easting",600000],PARAMETER["false_northing",200000],UNIT["Meter",1],AUTHORITY["EPSG","12345"]]</font></div>
<div>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3">- click on 'Finalize' and 'Accept'. You'll see that gvSIG refers to the new CRS as 'USR:1' or similar.</font></div>
<div><font color="#000000" face="Times New Roman" size="3">- click 'Accept' again and open the view</font></div>
<div><font color="#000000" face="Times New Roman" size="3">- add the file montreuil_27561.shp without any additional option because we know it's the same CRS of the view.</font></div>
<div><font color="#000000" face="Times New Roman" size="3">- go to the 'Add file' option again, choose the file montreuil_2154.shp and before clicking on 'Accept', click on the button to indicate the CRS of the file that is being added. Search for EPSG:2154 (this one has no problem, you can use it) and select it, then you need to choose the 'Manual transformation' option in the transformation combo box. The seven parameters are:</font></div>
<div>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3">168</font></div>
<div><font color="#000000" face="Times New Roman" size="3">60</font></div>
<div><font color="#000000" face="Times New Roman" size="3">-320</font></div>
<div><font color="#000000" face="Times New Roman" size="3">0</font></div>
<div><font color="#000000" face="Times New Roman" size="3">0</font></div>
<div><font color="#000000" face="Times New Roman" size="3">0</font></div>
<div><font color="#000000" face="Times New Roman" size="3">0</font></div>
<div>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3">- click 'Accept' on all the following dialogs, and both shapefiles should match. There is a small error of about 1.5 m, but I don't think that's a problem for you.</font></div>
<div>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3">Does this process work for you?</font></div>
<div><font color="#000000" face="Times New Roman" size="3"></font>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3">The CRS you have defined should be available from now on, but you will have to type the seven parameters each time from the 'Manual transformation' option.</font></div>
<div><font color="#000000" face="Times New Roman" size="3"></font>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3">Those seven parameters are valid if the view is in 'NTF Lambert Zone 1 France 2SP'. If the view is in EPSG:2154 and you add a shapefile in 'NTF Lambert Zone 1 France 2SP', you'll have to reverse the sign of the parameters.</font></div>
<div><font color="#000000" face="Times New Roman" size="3"></font>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3">If you don't want to deal with user CRS and parameters inside gvSIG, you can reproject your shapefiles before starting gvSIG. There is a nice free program that does that:</font></div>
<div><font color="#000000" face="Times New Roman" size="3"></font>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3"><a href="http://fwtools.maptools.org" target="_blank">http://fwtools.maptools.org</a></font></div>
<div><font color="#000000" face="Times New Roman" size="3"></font>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3">The command would be something like:</font></div>
<div><font color="#000000" face="Times New Roman" size="3"></font>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3">ogr2ogr -f "ESRI Shapefile" -s_srs epsg:2154 -t_srs epsg:27561 new_file.shp old_file_2154.shp</font></div>
<div><font color="#000000" face="Times New Roman" size="3"></font>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3">(but again, we should check the meaning of EPSG:27561 in that case)</font></div>
<div><font color="#000000" face="Times New Roman" size="3"></font>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3"></font>&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3">Regards,</font></div>
<div>&nbsp;</div>
<div><font face="Courier New" size="2"><font face="Times New Roman" size="3">Juan Lucas Domínguez Rubio<br></font>---</font></div></div>
<div id="idSignature27059">
<div><font face="Courier New" size="2"><font face="Courier New" size="2"><font face="Courier New" size="2">Prodevelop SL, Valencia (España)</font></font></font></div>
<div>
<div><font face="Courier New" size="2"><font face="Courier New" size="2"><font face="Courier New" size="2">Tlf.: 96.351.06.12 -- Fax: 96.351.09.68<br></font><a href="http://www.prodevelop.es/" target="_blank"><font face="Courier New" size="2">http://www.prodevelop.es</font></a><br><font face="Courier New" size="2">---</font></font></font></div><font face="Courier New" size="2"><font face="Courier New" size="2"></font></font></div><font face="Courier New" size="2"></font></div>
<div><br>
<hr>
<font face="Tahoma" size="2"><b>De:</b> gvsig_internacional-bounces@listserv.gva.es en nombre de Bouillot Michel<br><b>Enviado el:</b> jue 15/07/2010 14:22<br><b>Para:</b> Users and Developers mailing list<br><b>Asunto:</b> Re: [Gvsig_english] trouble with EPSG 2154 and 27561<br></font><br></div>
<div>
<div style="font-size: 12pt; color: rgb(0, 0, 0); font-family: Arial;">Hello,<br><br>I think that you are right.<br><br>I join shapefiles in both EPSG.<br><br>Thanks for the tests.<br><br>Regards,<br><br>Michel Bouillot<br><br>----- Mail Original -----<br>De: "Juan Lucas Dominguez Rubio" &lt;jldominguez@prodevelop.es&gt;<br>À: "Users and Developers mailing list" &lt;gvsig_internacional@listserv.gva.es&gt;, "Users and Developers mailing list" &lt;gvsig_internacional@listserv.gva.es&gt;<br>Envoyé: Jeudi 15 Juillet 2010 13:29:45<br>Objet: Re: [Gvsig_english] trouble with EPSG 2154 and 27561<br><br>
<style>p { margin: 0; }</style>

<div id="idOWAReplyText48021">
<div><font color="#000000" face="Times New Roman" size="3">Hello, I think there's a misunderstood.</font></div>
<div>&nbsp;</div>
<div>gvSIG is able to do on-the-fly reprojection (this is what Michel needs, I think).</div>
<div>&nbsp;</div>
<div>But I'm afraid that, even if he follows the right steps to do it, the result will be wrong because (I think) gvSIG does not know the right parameters to perform that conversion (between EPSG:2154 and EPSG:27561).</div>
<div>&nbsp;</div>
<div>There have been problems with the French projections in the past, and I'm not sure if they were caused by a bug in gvSIG or in the libraries used by gvSIG (especially Proj4).</div>
<div>&nbsp;</div>
<div>Michel: can you please send to the list two little shapefiles (one in EPSG:2154 and the other in EPSG:27561) that should match but do not match in gvSIG? So we can also do some tests.</div>
<div>&nbsp;</div>
<div>Regards,&nbsp;</div>
<div><font color="#000000" face="Times New Roman" size="3"></font>&nbsp;</div></div>
<div id="idSignature43969">
<div><font face="Courier New" size="2"><font face="Times New Roman" size="3">Juan Lucas Domínguez Rubio<br></font>---</font></div>
<div><font face="Courier New" size="2"><font face="Courier New" size="2"><font face="Courier New" size="2">Prodevelop SL, Valencia (España)</font></font></font></div>
<div>
<div><font face="Courier New" size="2"><font face="Courier New" size="2"><font face="Courier New" size="2">Tlf.: 96.351.06.12 -- Fax: 96.351.09.68<br></font><a href="http://www.prodevelop.es/" target="_blank"><font face="Courier New" size="2">http://www.prodevelop.es</font></a><br><font face="Courier New" size="2">---</font></font></font></div><font face="Courier New" size="2"><font face="Courier New" size="2"></font></font></div><font face="Courier New" size="2"></font></div>
<div><br>
<hr>
<font face="Tahoma" size="2"><b>De:</b> gvsig_internacional-bounces@listserv.gva.es en nombre de Bouillot Michel<br><b>Enviado el:</b> jue 15/07/2010 13:02<br><b>Para:</b> Users and Developers mailing list<br><b>Asunto:</b> Re: [Gvsig_english] trouble with EPSG 2154 and 27561<br></font><br></div>
<div>
<div style="font-size: 12pt; color: rgb(0, 0, 0); font-family: Arial;">Hi,<br><br>Thanks for this explanation.<br><br>I find GVSIG very good but in France we have just changed of RS. We begin to have data in the 2 RS. <br>The reprojection in the view would be very pactical !<br>Is there a hope for a such function in the futur ?<br><br>Regards<br><br>Michel Bouillot<br><br><br>----- Mail Original -----<br>De: "Guillermo Tamburini" &lt;tamburini_gui@gva.es&gt;<br>À: "Users and Developers mailing list" &lt;gvsig_internacional@listserv.gva.es&gt;<br>Envoyé: Jeudi 15 Juillet 2010 12:43:50<br>Objet: Re: [Gvsig_english] trouble with EPSG 2154 and 27561<br><br>Hi,<br><br>In fact, you can't correctly represent data in different reference systems in the same View (without reporojecting, it have no sense).<br><br>There are some software applications which applies&nbsp; automatically the reprojection, but it is not the case in gvSIG with vector layers.<br><br>First of all, you have to select the correct RS for your View, and then load the data (the target RS you are going to work). <br><br>Otherwise, you will see your data but in a incorrect situation. In other utm spindle, or displaced...<br><br>If your data is in different RS, you will have to reproject it. Goprocessing tools-&gt;Data Conversion-&gt;Reproject; the layer in the not current projection to the current projection.<br><br>Regards<br><br><br>Bouillot Michel wrote: 
<blockquote>
<style>p { margin: 0; }</style>

<div style="font-size: 12pt; color: rgb(0, 0, 0); font-family: Arial;">
<style>p { margin: 0; }</style>

<div style="font-size: 12pt; color: rgb(0, 0, 0); font-family: Arial;">
<style>p { margin: 0; }</style>

<div style="font-size: 12pt; color: rgb(0, 0, 0); font-family: Arial;">Hello,<br><br>I try to open in the same view one shp in EPSG 2154 and one SHP in EPSG 27561 but it don't match correctly. There is a problem with the X like a translation witch have a value who seems to be the difference between Greenwich and Paris meridian.<br><br>How to correct this trouble ?<br><br>regards<br><br></div><span id="e30d145b-dd99-4ef5-90f4-f6e11296c9ff"><strong>Michel Bouillot</strong><br>Chef de projet SIG<br>01 48 70 63 23 / <a class="moz-txt-link-abbreviated" href="mailto:michel.bouillot@montreuil.fr" target="_blank">michel.bouillot@montreuil.fr</a><br>Ville de Montreuil / Direction Urbanisme et Habitat<br>Service Études Développement Urbain<br>3, rue de Rosny / 93100 Montreuil<br><br></span></div></div><pre><hr size="4">
_______________________________________________
Gvsig_internacional mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Gvsig_internacional@listserv.gva.es" target="_blank">Gvsig_internacional@listserv.gva.es</a>
<a class="moz-txt-link-freetext" href="http://listserv.gva.es/cgi-bin/mailman/listinfo/gvsig_internacional" target="_blank">http://listserv.gva.es/cgi-bin/mailman/listinfo/gvsig_internacional</a>
  </pre></blockquote><br><br><pre class="moz-signature">-- 
Guillermo Tamburini Beliveau
Proyecto gvSIG 
Consellería de Infraestructuras y Transportes (GVA) 
Valencia (Spain) 
 
</pre><br>_______________________________________________<br>Gvsig_internacional mailing list<br>Gvsig_internacional@listserv.gva.es<br>http://listserv.gva.es/cgi-bin/mailman/listinfo/gvsig_internacional<br></div></div><br>_______________________________________________<br>Gvsig_internacional mailing list<br>Gvsig_internacional@listserv.gva.es<br>http://listserv.gva.es/cgi-bin/mailman/listinfo/gvsig_internacional<br></div></div><br>_______________________________________________<br>Gvsig_internacional mailing list<br>Gvsig_internacional@listserv.gva.es<br>http://listserv.gva.es/cgi-bin/mailman/listinfo/gvsig_internacional<br></div></body></html>