-
-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WMS raster transparency problem #11593
Comments
Author Name: John Tull (John Tull) I realize now that the link can be shortened to: http://toposervices.cr.usgs.gov/wmsconnector/com.esri.wms.Esrimap/USGS_EDNA_geo? |
Author Name: ersts - (ersts -) This is a known issue. If you keep repeatedly hitting apply, the transparency it is additive. Likewise, if you decrease the transparency, it is still additive. However, if you pan the map canvas a little and cause a new fetch request, your layer will be at the correct/expected transparency level. It seems to be a bug in Qt with setting the alpha value for an image more than once. Each apply causes a refresh and thus a reapplication of the alpha value. Too speed things up, the WMS provider does not request a new version of the image if the extent has not changed, it uses a cached version. I am going to downgrade this a little, while it needs to get fixed but it does not cause a crash or a damage of data
|
Author Name: John Tull (John Tull) Peter: Thanks for the detailed explanation. I did not see a bug filed, so added it this weekend. It sounds like I need to be filing bugs against Qt instead... Also, it's good to know that forcing a wms refresh works around the problem. |
Author Name: ersts - (ersts -) I think it is more just that setAlphaChannel() does not work quite a expected. When you use that method it changes the image format to QImage::Format_ARGB32_Premultiplied
So I changed it around a little have had the WMS Provider store a QImage::Format_ARGB32 then just adjusted the pixel values on each refresh. WMS images should be small enough to not see any performance hit. The mods were made to the trunk r:10146. If you can take it for a spin and make sure it works more as expected. If it does I will close the ticket and add it to the Version-1_0 branch for inclusion in the next release. |
Author Name: John Tull (John Tull) It does appear to be working now. Great! I closed the ticket.
|
Author Name: Anónimo (Anónimo) Milestone Version 1.0.1 deleted |
Author Name: John Tull (John Tull)
Original Redmine Issue: 1533
Redmine category:map_canvas
Assignee: ersts -
It appears that a WMS raster layer with transparency set in the layer properties will increase transparency with every screen refresh until it becomes invisible. To replicate, try the NED shaded relief layer from:
http://toposervices.cr.usgs.gov/wmsconnector/com.esri.wms.Esrimap/USGS_EDNA_geo?WMTVER=1.1.1&LAYERS=NED_2003_SHADEDRELIEF&SRS=EPSG:4326&FORMAT=PNG&BGCOLOR=0xFF0000&TRANSPARENT=true&SERVICE=WMS&STYLES=&REQUEST=capabilities
The text was updated successfully, but these errors were encountered: