Opened 14 years ago
Last modified 14 years ago
#3546 new defect
Getlegendgraphic with sizeunit METERS set does not work
Reported by: | tenglich | Owned by: | assefa |
---|---|---|---|
Priority: | normal | Milestone: | 5.6.5 release |
Component: | WMS Server | Version: | 5.6 |
Severity: | normal | Keywords: | |
Cc: | sholl |
Description
Hello,
we have got problems using the GetLegendGraphic-Request. If we use it requesting the layer explained below we get no symbol drawn into the image which is delivered. only the name of the layer was drawn.
We analized the issue and detect that this problem occours if the scalefactor which is used to draw the symbol is very small.
We create a fix which solve this problem. But the fix will disable the possibility that an symbol is drawn smaller than scalefactor = 1 in the legendgraphic and not using the size the symbol will have using the max-extent of the map.
Here is the Layer which does not work:
LAYER NAME "mylayer" STATUS ON TYPE LINE TEMPLATE "mytemplate.html" HEADER "myheader.html" FOOTER "myfooter.html" MINSCALEDENOM 0 MAXSCALEDENOM 165000 TOLERANCE 20 TOLERANCEUNITS METERS SIZEUNITS METERS METADATA WMS_TITLE "mytitle" WMS_SRS "epsg:31467" WMS_FEATURE_INFO_MIME_TYPE "text/html" WMS_EXTENT "3457312.92 5753546.26 3467917 5764666.5" END PROJECTION "init=epsg:31467" END DATA "myshape.shp" CLASSITEM "objectid" CLASS NAME "myclass" EXPRESSION /./ STYLE SYMBOL 'circle' COLOR 144 50 207 SIZE 7 END END END
Attachments (3)
Change History (8)
by , 14 years ago
Attachment: | diff_branch-5-6.diff added |
---|
by , 14 years ago
Attachment: | diff_trunk.diff added |
---|
comment:1 by , 14 years ago
Cc: | added |
---|
comment:2 by , 14 years ago
Component: | MapServer C Library → WFS Client |
---|---|
Owner: | changed from | to
comment:3 by , 14 years ago
Component: | WFS Client → WMS Server |
---|
follow-up: 5 comment:4 by , 14 years ago
comment:5 by , 14 years ago
Replying to assefa:
have you tried setting the minsize parameter to 1 in your style object and see if you get the symbol?
Hello,
yes it works using the minsize parameter. but using it takes affect to the map as well, which is often not a good idea.
We also find another Bug in the Legend-Graphic using the Windows Build of 5.7-dev:
If we use the underlying Layer the different Icons of the different Classes are rendered in a wrong height.
{{{LAYER
NAME "mylayer" STATUS ON TYPE LINE TEMPLATE "query.html" HEADER "header.html" FOOTER "gfooter.html" TOLERANCE 20 TOLERANCEUNITS METERS #PIXELS SIZEUNITS METERS #PIXELS
METADATA
WMS_TITLE "mylayer" WMS_SRS "epsg:31467" WMS_FEATURE_INFO_MIME_TYPE "text/html" WMS_EXTENT "3457312.92 5753546.26 3478522.40 5775787.08"
END
PROJECTION
"init=epsg:31467"
END
DATA myshape.shp"
CLASSITEM "id"
CLASS
NAME "name1" EXPRESSION /./ MINSCALEDENOM 1 MAXSCALEDENOM 1400
STYLE
SYMBOL 'circle' COLOR 144 50 207 SIZE 7
END
END CLASS
NAME "name1" EXPRESSION /./ MINSCALEDENOM 1350 MAXSCALEDENOM 5000
STYLE
SYMBOL 'circle' COLOR 144 50 207 SIZE 27
END
END CLASS
NAME "name1" EXPRESSION /./ MINSCALEDENOM 4800 MAXSCALEDENOM 50000
STYLE
SYMBOL 'circle' COLOR 144 50 207 SIZE 57
END
END CLASS
NAME "name1" EXPRESSION /./ MINSCALEDENOM 48000 MAXSCALEDENOM 150000
STYLE
SYMBOL 'circle' COLOR 144 50 207 SIZE 77
END
END
END
}}}
have you tried setting the minsize parameter to 1 in your style object and see if you get the symbol?