TransWikia.com

PNG from GeoServer size on Google Earth seems uncontrollable

Geographic Information Systems Asked by jpmaniac87 on June 27, 2021

I have set up a GeoServer instance that hosts a lot of data that we process at work. It seems to be the easiest way to distribute since I can provide a simple network link to the GeoServer so that others can view it in Google Earth. In this case, I have a bunch of points that I have created a style for. The style is a PNG for each type. Here is an excerpt from my SLD:

<PointSymbolizer>
    <Graphic>
        <ExternalGraphic>
          <OnlineResource xlink:type="simple" xlink:href="towerBlue.png" />
          <Format>image/png</Format>
        </ExternalGraphic>
        <Size>10</Size>
    </Graphic>
</PointSymbolizer>

The sizes of these seem to be all out of whack. When zoomed out, they are tiny, but when I zoom in literally 2 wheel clicks from where the first screenshot comes from, they cover the whole screen. What could I be doing wrong here? Also, SVG didn’t work for me at all, which is why I’m using PNG.

Symbols very small

GIANT SYMBOLS!!

One Answer

In my case the solution was replacing de format of the image.

Doing this:

Replace

<Format>image/png</Format

with

<Format>application/vnd.google-earth.kml+XML</Format>

<PointSymbolizer>
   <Graphic>
      <ExternalGraphic>
         <OnlineResource xlink:type="simple" xlink:href="http://geoserver.112ib.com/styles/SEIB112/imagenes/olimpic.png"/>
         <Format>application/vnd.google-earth.kml+XML</Format>
      </ExternalGraphic>
   </Graphic>
</PointSymbolizer>

Answered by am4rtinez on June 27, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP