<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
    <title></title>
  </head>
  <body bgcolor="#ffffff" text="#000000">
    Hola a todos (Jorge y Jorge et al.)<br>
    <br>
    Ayer estava mirando al libro de OpenLayers2.10, y dicia muy claro:<br>
    <br>
    "Se tienes un google layer como base, y tienes que anadir un WMS, el
    WMS tiene que esta en el mismo proyectado de google (EPSG:900913)",
    (aun que EPSG:3785 sea +-/ el mismo.)<br>
    <br>
    Tu servidor WMS tiene que suportar el EPSG:900913, y OpenLayers solo
    va a trabajar con este proyectado.<br>
    <br>
    Y por el pop up de map data, tienes que anadir el seguinte CSS:<br>
    <br>
    .olLayerGoogleCopyright {<br>
    &nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; visibility:hidden;<br>
    }<br>
    <br>
    <br>
    o entonces algo como top:-10000px;<br>
    <br>
    Jorge<br>
    <br>
    On 12/06/11 19:03, Ragi Burhum wrote:
    <blockquote
      cite="mid:BANLkTinB4Koni2np0DPFBZ0BERb=ocwGuA@mail.gmail.com"
      type="cite">
      <div class="gmail_quote">
        <div>Jorge y Jorge :)</div>
        <div><br>
        </div>
        <div>Ya puse una respuesta a esta pregunta en <a
            moz-do-not-send="true" href="http://GIS.SE">GIS.SE</a>&nbsp;<a
            moz-do-not-send="true"
href="http://gis.stackexchange.com/questions/10916/openlayers-weird-problem-with-googlemaps-base-layer-and-wms-overlay/10920#10920">http://gis.stackexchange.com/questions/10916/openlayers-weird-problem-with-googlemaps-base-layer-and-wms-overlay/10920#10920</a></div>
        <div><br>
        </div>
        <div>Inclusive, uno de los creadores de Openlayers le di&oacute; un +1
          a la respuesta, as&iacute; que pueden estar seguros que es la
          correcta. :)</div>
        <div><br>
        </div>
        <div>Saludos,</div>
        <div><br>
        </div>
        <div>- Ragi</div>
        <div>
          &nbsp;</div>
        <blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt
          0.8ex; border-left: 1px solid rgb(204, 204, 204);
          padding-left: 1ex;">Message: 1<br>
          Date: Sun, 12 Jun 2011 16:41:29 +0200<br>
          From: Jorge Ar?valo &lt;<a moz-do-not-send="true"
            href="mailto:jorge.arevalo@deimos-space.com">jorge.arevalo@deimos-space.com</a>&gt;<br>
          Subject: Re: [Spanish] WMS Catastro + OpenLayers<br>
          To: "Cap&amp;amp, amp, amp, #237, &nbsp; tulo Local de la comunidad<br>
          &nbsp; &nbsp; &nbsp; &nbsp;hispano-hablante" &lt;<a moz-do-not-send="true"
            href="mailto:spanish@lists.osgeo.org">spanish@lists.osgeo.org</a>&gt;<br>
          Message-ID: &lt;BANLkTi=<a moz-do-not-send="true"
            href="mailto:2c9hYjsidC3vEPtg19Fm4WvQLtQ@mail.gmail.com">2c9hYjsidC3vEPtg19Fm4WvQLtQ@mail.gmail.com</a>&gt;<br>
          Content-Type: text/plain; charset=ISO-8859-1<br>
          <br>
          Buenas,<br>
          <br>
          Muchas gracias crack. La pena es que no me ha funcionado :-(.
          He<br>
          probado tambi&eacute;n a usar la versi&oacute;n estable de OpenLayers<br>
          <a moz-do-not-send="true"
            href="http://openlayers.org/api/OpenLayers.js"
            target="_blank">http://openlayers.org/api/OpenLayers.js</a>,
          en lugar de la versi&oacute;n en<br>
          desarrollo, y me dice lo mismo.<br>
          <br>
          Otra cosa algo molesta es que siempre me sale un popup con el<br>
          copyright de TeleAtlas. Pero bueno, es un problema menor. Si
          conseguis<br>
          poner el WMS del catastro sobre una capa de GoogleMaps en
          OpenLayers,<br>
          me har&eacute;is un gran favor. Ya digo que con la API de Google Maps<br>
          directamente ha sido sencillo.<br>
          <br>
          Muchas gracias en cualquier caso :-)<br>
          <br>
          Jorge<br>
          <br>
          2011/6/12 Jorge Gaspar Sanz Salinas &lt;<a
            moz-do-not-send="true" href="mailto:jsanz@osgeo.org">jsanz@osgeo.org</a>&gt;:<br>
          &gt; El 11/06/2011 17:41, Jorge Ar&eacute;valo escribi&oacute;:<br>
          &gt;&gt; Buenas,<br>
          &gt;&gt;<br>
          &gt;&gt; Estoy intentando superponer una capa del WMS del
          catastro sobre una<br>
          &gt;&gt; capa base de GoogleMaps en OpenLayers. Usando la API
          de GoogleMaps lo<br>
          &gt;&gt; hice sin problemas, aprovechando que el WMS del
          catastro ofrece el<br>
          &gt;&gt; EPSG:3785, pero al intentarlo en OpenLayers me est&aacute;
          pasando una cosa<br>
          &gt;&gt; rara. Me explico:<br>
          &gt;&gt;<br>
          &gt;&gt; Si la capa la defino as&iacute; en OpenLayers<br>
          &gt;&gt;<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; var catastro_layer = new OpenLayers.Layer.WMS(<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; "WMS Catastro",<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; "<a moz-do-not-send="true"
href="http://ovc.catastro.meh.es/Cartografia/WMS/ServidorWMS.aspx?SERVICE=WMS&amp;VERSION=1.1.1"
            target="_blank">http://ovc.catastro.meh.es/Cartografia/WMS/ServidorWMS.aspx?SERVICE=WMS&amp;VERSION=1.1.1</a>",<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; layers: "catastro",<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; format:"image/png",<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; srs: "EPSG:3785",<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; transparent: false<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; );<br>
          &gt;&gt;<br>
          &gt;&gt; Me aparece la capa WMS como una capa m&aacute;s, elegible en
          lugar de la de<br>
          &gt;&gt; Google, pero NO superponible sobre ella. En esta
          captura se ve lo que<br>
          &gt;&gt; quiero decir: <a moz-do-not-send="true"
            href="http://dl.dropbox.com/u/6599273/capa_wms1.png"
            target="_blank">http://dl.dropbox.com/u/6599273/capa_wms1.png</a><br>
          &gt;&gt;<br>
          &gt;&gt; En este caso, la petici&oacute;n WMS se genera
          correctamente. Aqu&iacute; un ejemplo:<br>
          &gt;&gt;<br>
          &gt;&gt; <a moz-do-not-send="true"
href="http://ovc.catastro.meh.es/Cartografia/WMS/ServidorWMS.aspx?SERVICE=WMS&amp;VERSION=1.1.1&amp;LAYERS=catastro&amp;FORMAT=image%2Fpng&amp;SRS=EPSG%3A3785&amp;TRANSPARENT=false&amp;REQUEST=GetMap&amp;STYLES=&amp;EXCEPTIONS=application%2Fvnd.ogc.se_inimage&amp;BBOX=-1721973.3737,3228700.0733875,-1702405.4944625,3248267.952625&amp;WIDTH=256&amp;HEIGHT=256"
            target="_blank">http://ovc.catastro.meh.es/Cartografia/WMS/ServidorWMS.aspx?SERVICE=WMS&amp;VERSION=1.1.1&amp;LAYERS=catastro&amp;FORMAT=image%2Fpng&amp;SRS=EPSG%3A3785&amp;TRANSPARENT=false&amp;REQUEST=GetMap&amp;STYLES=&amp;EXCEPTIONS=application%2Fvnd.ogc.se_inimage&amp;BBOX=-1721973.3737,3228700.0733875,-1702405.4944625,3248267.952625&amp;WIDTH=256&amp;HEIGHT=256</a><br>
          &gt;&gt;<br>
          &gt;&gt; Pero no me vale porque yo quiero la capa WMS encima
          de la de Google<br>
          &gt;&gt; Maps, no en lugar de ella.<br>
          &gt;&gt;<br>
          &gt;&gt; En cambio, si defino la capa as&iacute; (solo he cambiado el
          transparent de<br>
          &gt;&gt; false a true):<br>
          &gt;&gt;<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; var catastro_layer = new OpenLayers.Layer.WMS(<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; "WMS Catastro",<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; "<a moz-do-not-send="true"
href="http://ovc.catastro.meh.es/Cartografia/WMS/ServidorWMS.aspx?SERVICE=WMS&amp;VERSION=1.1.1"
            target="_blank">http://ovc.catastro.meh.es/Cartografia/WMS/ServidorWMS.aspx?SERVICE=WMS&amp;VERSION=1.1.1</a>",<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; layers: "catastro",<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; format:"image/png",<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; srs: "EPSG:3785",<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; transparent: true<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br>
          &gt;&gt; &nbsp; &nbsp; &nbsp; );<br>
          &gt;&gt;<br>
          &gt;&gt; La capa WMS ya aparece como una capa superpuesta
          sobre la capa base<br>
          &gt;&gt; (como si hubiera especificado "isBaseLayer:false",
          aunque no lo he<br>
          &gt;&gt; hecho). En la captura se ve:<br>
          &gt;&gt; <a moz-do-not-send="true"
            href="http://dl.dropbox.com/u/6599273/capa_wms2.png"
            target="_blank">http://dl.dropbox.com/u/6599273/capa_wms2.png</a><br>
          &gt;&gt;<br>
          &gt;&gt; Lo que sucede ahora con la petici&oacute;n, es que se hace
          de manera<br>
          &gt;&gt; incorrecta. Me cambia el epsg:3785 por epsg:900913 (a
          pesar de que yo<br>
          &gt;&gt; lo he especificado el 3785, como se puede ver, y el
          servidor lo<br>
          &gt;&gt; acepta). Y al cambiarlo, el servidor me devuelve
          error. Aqu&iacute; un<br>
          &gt;&gt; ejemplo de las peticiones que genera en este segundo
          caso, devolviendo<br>
          &gt;&gt; error por el epsg:<br>
          &gt;&gt;<br>
          &gt;&gt; <a moz-do-not-send="true"
href="http://ovc.catastro.meh.es/Cartografia/WMS/ServidorWMS.aspx?SERVICE=WMS&amp;VERSION=1.1.1&amp;LAYERS=catastro&amp;FORMAT=image%2Fpng&amp;SRS=EPSG%3A900913&amp;TRANSPARENT=true&amp;REQUEST=GetMap&amp;STYLES=&amp;EXCEPTIONS=application%2Fvnd.ogc.se_inimage&amp;BBOX=-1721973.3737,3228700.0733875,-1702405.4944625,3248267.952625&amp;WIDTH=256&amp;HEIGHT=256"
            target="_blank">http://ovc.catastro.meh.es/Cartografia/WMS/ServidorWMS.aspx?SERVICE=WMS&amp;VERSION=1.1.1&amp;LAYERS=catastro&amp;FORMAT=image%2Fpng&amp;SRS=EPSG%3A900913&amp;TRANSPARENT=true&amp;REQUEST=GetMap&amp;STYLES=&amp;EXCEPTIONS=application%2Fvnd.ogc.se_inimage&amp;BBOX=-1721973.3737,3228700.0733875,-1702405.4944625,3248267.952625&amp;WIDTH=256&amp;HEIGHT=256</a><br>
          &gt;&gt;<br>
          &gt;&gt; Resumiendo lo que pasa, cuando transparent es
          'false', la capa se<br>
          &gt;&gt; interpreta como capa base, y la petici&oacute;n se genera
          correctamente. Pero<br>
          &gt;&gt; cuando transparent es 'true', la capa se interpreta
          como overlay, que<br>
          &gt;&gt; es lo que yo quiero, pero la petici&oacute;n se hace de
          manera err&oacute;nea,<br>
          &gt;&gt; porque me cambia el epsg.<br>
          &gt;&gt;<br>
          &gt;&gt; &iquest;Alguna pista de porqu&eacute; pasa esto? Estoy usando esta
          versi&oacute;n de<br>
          &gt;&gt; OpenLayers directamente <a moz-do-not-send="true"
            href="http://openlayers.org/api/OpenLayers.js"
            target="_blank">http://openlayers.org/api/OpenLayers.js</a><br>
          &gt;&gt;<br>
          &gt;&gt; Muchas gracias por adelantado, un saludo<br>
          &gt;&gt;<br>
          &gt;&gt;<br>
          &gt;<br>
          &gt; Mira a ver si esto[1] te vale tocayo.B&aacute;sicamente me he
          sacado de la<br>
          &gt; manga un par&aacute;metro reproject de este ejemplo[3].<br>
          &gt;<br>
          &gt; Pero cuidad&iacute;n que ese par&aacute;metro esta deprecated[3] y es
          m&aacute;s bien un<br>
          &gt; hack, deber&iacute;a haber una forma de conseguir instanciar un
          mapa en 3785 y<br>
          &gt; que catastro funcione, si lo saco te aviso.<br>
          &gt;<br>
          &gt; [1] <a moz-do-not-send="true"
            href="http://pastebin.com/gSVFU1id" target="_blank">http://pastebin.com/gSVFU1id</a><br>
          &gt; [2] <a moz-do-not-send="true"
            href="http://openlayers.org/dev/examples/google-reproject.html"
            target="_blank">http://openlayers.org/dev/examples/google-reproject.html</a><br>
          &gt; [3]<br>
          &gt; <a moz-do-not-send="true"
href="http://dev.openlayers.org/releases/OpenLayers-2.6/doc/apidocs/files/OpenLayers/Layer/HTTPRequest-js.html#OpenLayers.Layer.HTTPRequest.reproject"
            target="_blank">http://dev.openlayers.org/releases/OpenLayers-2.6/doc/apidocs/files/OpenLayers/Layer/HTTPRequest-js.html#OpenLayers.Layer.HTTPRequest.reproject</a><br>
          &gt;<br>
          &gt; --<br>
          &gt; Jorge Gaspar Sanz Salinas<br>
          &gt; <a moz-do-not-send="true" href="http://es.osgeo.org"
            target="_blank">http://es.osgeo.org</a><br>
          &gt; <a moz-do-not-send="true" href="http://jorgesanz.net"
            target="_blank">http://jorgesanz.net</a><br>
        </blockquote>
      </div>
      <pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
Spanish mailing list
<a class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/spanish">http://lists.osgeo.org/mailman/listinfo/spanish</a>
<a class="moz-txt-link-freetext" href="http://es.osgeo.org">http://es.osgeo.org</a>
<a class="moz-txt-link-freetext" href="http://twitter.com/osgeoes">http://twitter.com/osgeoes</a>
</pre>
    </blockquote>
    <br>
  <br />
<hr />
<p><font face="Arial" size="1">
Plymouth Marine Laboratory<br />
Registered Office: <br />
Prospect Place<br />
The Hoe<br />
Plymouth  PL1 3DH
</font></p>

<p><font face="Arial" size="1">Website: <a href="http://www.pml.ac.uk">www.pml.ac.uk</a>
<br />
<a href="http://www.pml.ac.uk/pdf/PMLAR2010.pdf">Click here for PML Annual Review 2010 </a>
<br />
Registered Charity No. 1091222<br />
PML is a company limited by guarantee<br />
registered in England & Wales<br />
company number 4178503</font></p>

<p><font face="Arial" size="1" color="green">Please think before you print.</font></p>

<hr />

<p><font face="Arial" size="1">This e-mail, its content and any file attachments are confidential.</font></p>

<p><font face="Arial" size="1">If you have received this e-mail in error please do not copy, disclose it to any third party or use the contents or attachments in any way. Please notify the sender by replying to this e-mail or e-mail forinfo@pml.ac.uk and then delete the email without making any copies or using it in any other way.</font></p>

<p><font face="Arial" size="1">The content of this message may contain personal views which are not the views of Plymouth Marine Laboratory unless specifically stated.</font></p>

<p><font face="Arial" size="1">You are reminded that e-mail communications are not secure and may contain viruses. Plymouth Marine Laboratory accepts no liability for any loss or damage which may be caused by viruses.</font></p>

<hr />
<br />
<br /></body>
</html>