[Geoserver-devel] [jira] (GEOS-4913) A disappearing scaleline

Simon Sandlund created GEOS-4913:
------------------------------------

             Summary: A disappearing scaleline
                 Key: GEOS-4913
                 URL: https://jira.codehaus.org/browse/GEOS-4913
             Project: GeoServer
          Issue Type: Bug
          Components: WMS
    Affects Versions: 2.1.1
         Environment: Linux RHEL 5.
            Reporter: Simon Sandlund
            Assignee: Andrea Aime
         Attachments: image1.png, image2.png

The following request, for a single layer, displays the scaleline without issues:
http://<server>:8090/geoserver/wms?service=WMS&version=1.1.0&REQUEST=GetMap&srs=EPSG%3A3006&transparent=true&LAYERS=metria%3AGV_ATGARDSOMRADE&STYLES=&BBOX=691998.412628%2C7167403.921064001%2C700869.793412%2C7179344.229416&width=1058&height=1424&format=image%2Fpng&FORMAT_OPTIONS=layout%3Atgis;dpi%3A150&ENV=admin%3Atrue;org%3Ametria

See image1.png. Layout "tgis" specifies the scaleline shown.

This next one, identical except for a slightly larger bounding box, has no scaleline:
http://twtest1.lulea.lm.se:8090/geoserver/wms?service=WMS&version=1.1.0&REQUEST=GetMap&srs=EPSG%3A3006&transparent=true&LAYERS=metria%3AGV_ATGARDSOMRADE&STYLES=&BBOX=691998.3230506667%2C7167403.800498667%2C700869.8829893334%2C7179344.349981333&width=1058&height=1424&format=image%2Fpng&FORMAT_OPTIONS=layout%3Atgis;dpi%3A150&ENV=admin%3Atrue;org%3Ametria

See image2.png.

In case it's relevant, I noticed that the scale denominator computed for these request differ by one:

The first, working, example:
[geotools.rendering] - Computed scale denominator: 49518.00000000021
[geotools.styling] - number of fts set 1
[geotools.rendering] - processing 1 stylers for http://metria.se:GV_ATGARDSOMRADE
[geotools.rendering] - creating rules for scale denominator - 49,518
[geotools.rendering] - Expanding rendering area by 3 pixels to consider stroke width
[geotools.rendering] - Querying layer http://metria.se:GV_ATGARDSOMRADE with bbox: ReferencedEnvelope[691973.2574840001 : 700894.948556, 7167378.76592 : 7179369.38456]

The second example, not working:
[geotools.rendering] - Computed scale denominator: 49518.999999999876
[geotools.styling] - number of fts set 1
[geotools.rendering] - processing 1 stylers for http://metria.se:GV_ATGARDSOMRADE
[geotools.rendering] - creating rules for scale denominator - 49,519
[geotools.rendering] - Expanding rendering area by 3 pixels to consider stroke width
[geotools.rendering] - Querying layer http://metria.se:GV_ATGARDSOMRADE with bbox: ReferencedEnvelope[691973.1673986667 : 700895.0386413333, 7167378.644846668 : 7179369.505633333]

But, the SLD for the layer in question makes no reference to this scale denominator - but that might be barking up the wrong tree - are SLDs at all able to affect the visibility of map decorations?

By the way, these particular numbers are probably not important. The numbers change when other factor change (image size, for example).
Sometimes changing the order of the requested layers will make this issue go away (in this example I've only used 1 layer, but in reality several are often requested).

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira