Opened 18 years ago
Last modified 18 years ago
#1733 new defect
SLD problem with FE on geometry
Reported by: | Owned by: | mapserverbugs | |
---|---|---|---|
Priority: | high | Milestone: | |
Component: | WMS Server | Version: | 4.8 |
Severity: | normal | Keywords: | |
Cc: |
Description
I've found some peculiar behaviour in WMS service with SLD on Mapserver 4.9, A) FE on geometry (Layer default EPSG:4326) ------------------------------------------- 1) WMS Query build by Mapserver (SLD filter on geometry) (EPSG:4326) http://gesteau.oieau.fr/service?LAYERS=SAGEMO,SAGEEL,SAGEIN&REQUEST=GetMap&SERVICE=WMS&FORMAT=image%2Fpng&STYLES=,,&HEIGHT=410&VERSION=1.1.1&SRS=EPSG:4326&WIDTH=500&SLD=http%3A%2F%2Fsandre%2Eeaufrance%2Efr%2Fgis%2Fsandre%2Fcartoweb3%2Fhtdocs%2Fgenerated%2Fsld%2Fsld%5FNBtvD8&BBOX=%2D2%2E79128927817547%2C42%2E7053261532691%2C2%2E27650328960573%2C45%2E7275512906587&TRANSPARENT=TRUE&EXCEPTIONS=application/vnd.ogc.se_inimage ==> Blank image 2) Same query but with SLD attribute on tail http://gesteau.oieau.fr/service?LAYERS=SAGEMO,SAGEEL,SAGEIN&REQUEST=GetMap&SERVICE=WMS&FORMAT=image%2Fpng&STYLES=,,&HEIGHT=410&VERSION=1.1.1&SRS=EPSG:4326&WIDTH=500&BBOX=%2D2%2E79128927817547%2C42%2E7053261532691%2C2%2E27650328960573%2C45%2E7275512906587&TRANSPARENT=TRUE&EXCEPTIONS=application/vnd.ogc.se_inimage&SLD=http%3A%2F%2Fsandre%2Eeaufrance%2Efr%2Fgis%2Fsandre%2Fcartoweb3%2Fhtdocs%2Fgenerated%2Fsld%2Fsld%5FNBtvD8 ==> Display features, even if projection seems quite strange 3) Same as previous but use ESPG:27582 instead http://gesteau.oieau.fr/service?LAYERS=SAGEMO,SAGEEL,SAGEIN&REQUEST=GetMap&SERVICE=WMS&FORMAT=image%2Fpng&STYLES=,,&HEIGHT=410&VERSION=1.1.1&SRS=EPSG:27582&WIDTH=500&BBOX=200245%2E256097561%2C1757044%2C595075%2E743902439%2C2080805&TRANSPARENT=TRUE&EXCEPTIONS=application/vnd.ogc.se_inimage&SLD=http%3A%2F%2Fsandre%2Eeaufrance%2Efr%2Fgis%2Fsandre%2Fcartoweb3%2Fhtdocs%2Fgenerated%2Fsld%2Fsld%5FNBtvD8 ==> Blank image 4) Same as previous but without SLD http://gesteau.oieau.fr/service?LAYERS=SAGEMO,SAGEEL,SAGEIN&REQUEST=GetMap&SERVICE=WMS&FORMAT=image%2Fpng&STYLES=,,&HEIGHT=410&VERSION=1.1.1&SRS=EPSG:27582&WIDTH=500&BBOX=200245%2E256097561%2C1757044%2C595075%2E743902439%2C2080805&TRANSPARENT=TRUE&EXCEPTIONS=application/vnd.ogc.se_inimage ==> Seems to Work fine B) FE on attribute ------------- WMS Query build by Mapserver (SLD filter on attribute) http://gesteau.oieau.fr/service?LAYERS=SAGEMO,SAGEEL,SAGEIN&REQUEST=GetMap&SERVICE=WMS&FORMAT=image%2Fpng&STYLES=,,&HEIGHT=410&VERSION=1.1.1&SRS=EPSG:4326&WIDTH=500&SLD=http%3A%2F%2Fsandre%2Eeaufrance%2Efr%2Fgis%2Fsandre%2Fcartoweb3%2Fhtdocs%2Fgenerated%2Fsld%2Fsld%5F6AWZaS&BBOX=%2D2%2E79128927817547%2C42%2E7053261532691%2C2%2E27650328960573%2C45%2E7275512906587&TRANSPARENT=TRUE&EXCEPTIONS=application/vnd.ogc.se_inimage ==> Seems to Work fine Same one on EPSG:27582 http://gesteau.oieau.fr/service?LAYERS=SAGEMO,SAGEEL,SAGEIN&REQUEST=GetMap&SERVICE=WMS&FORMAT=image%2Fpng&STYLES=,,&HEIGHT=410&VERSION=1.1.1&SRS=EPSG:27582&WIDTH=500&SLD=http%3A%2F%2Fsandre%2Eeaufrance%2Efr%2Fgis%2Fsandre%2Fcartoweb3%2Fhtdocs%2Fgenerated%2Fsld%2Fsld%5F6AWZaS&BBOX=200245%2E256097561%2C1757044%2C595075%2E743902439%2C2080805&TRANSPARENT=TRUE&EXCEPTIONS=application/vnd.ogc.se_inimage ==> Seems to Work fine C) FE on geometry (Layer default EPSG:27582) ------------- WMS Query build by Mapserver (SLD filter on geometry) (EPSG:27582) http://services.sandre.eaufrance.fr/geo/zonage?LAYERS=CIBA&REQUEST=GetMap&SERVICE=WMS&FORMAT=image%2Fpng&STYLES=&HEIGHT=410&VERSION=1.1.1&SRS=EPSG:27582&WIDTH=500&SLD=http%3A%2F%2Fsandre%2Eeaufrance%2Efr%2Fgis%2Fsandre%2Fcartoweb3%2Fhtdocs%2Fgenerated%2Fsld%2Fsld%5FKUBW34&BBOX=200245%2E256097561%2C1757044%2C595075%2E743902439%2C2080805&TRANSPARENT=TRUE&EXCEPTIONS=application/vnd.ogc.se_inimage ==> Seems to Work fine Same one with ESPG:4326 http://services.sandre.eaufrance.fr/geo/zonage?LAYERS=CIBA&REQUEST=GetMap&SERVICE=WMS&FORMAT=image%2Fpng&STYLES=&HEIGHT=410&VERSION=1.1.1&SRS=EPSG:4326&WIDTH=500&SLD=http%3A%2F%2Fsandre%2Eeaufrance%2Efr%2Fgis%2Fsandre%2Fcartoweb3%2Fhtdocs%2Fgenerated%2Fsld%2Fsld%5FKUBW34&BBOX=%2D2%2E79128927817547%2C42%2E7053261532691%2C2%2E27650328960573%2C45%2E7275512906587&TRANSPARENT=TRUE&EXCEPTIONS=application/vnd.ogc.se_inimage ==> Seems to Work fine HTH :)
Attachments (3)
Change History (6)
by , 18 years ago
Attachment: | sld_6AWZaS added |
---|
comment:1 by , 18 years ago
I found the problem and a way to solve this one. But I want to be sure there will be no other side-effect. The problem is caused by the nonsquare pixel handling and SLD with Shape filter. By using a SLD, we force the mapObj to validate it's extent and projection before the map drawing (during the msQueryByRect). And since we change the width and height, the mapObj will enable the nonsquare pixel mode and change the projection during the map drawing. But since the check of projection on the layer is already done (during the msQueryByRect), the layer is not reprojected for the nonsquare pixel mode. The nonsquare pixel mode use a fake projection. The solution I see is to reset the project layer parameter (is used to see if a layer needs to be projected or not) where the fake projection is created. Does it make sense? Also, I noticed that if you put the SLD at the end of the GetMap URL, the nonsquare pixel mode is not activated. Is a bug or a feature?
comment:2 by , 18 years ago
I think that's what was happening the last time, I though I send a patch to correct it to olivier. I might not have commied it (I do not see any thing in the logs). Please do the correction. As for the 2nd quetions : It does not look like a feature :) The order should not matter. I am pretty sure that I also checked that last time. So it should be corrected. I am not sure I will be able to look at this before tomorrow so do the changes. If there are issues I will check early next week.
comment:3 by , 18 years ago
I've commit the change to reset the layer projection. However, I'm not sure how to fix the second problem, the different result depending if the SLD is at the end or at the beginning of the URL. It's mainly the same problem. msQueryByShape Adjust the extent of the mapObj. If we do it after reading the width/height/bbox from the WMS GetMap URL, this disable the nonsquare pixel mode. If we do it before the mode is kept enabled. Since Assefa already investigate that, I won't dig any further and let him do it. Olivier, did Assefa provided you with a patch for this problem before? If yes, can you attach it to the bug?
Note:
See TracTickets
for help on using tickets.
SLD file