[Marble-devel] layer render sequence
Bernhard Beschow
bbeschow at cs.tu-berlin.de
Fri Aug 26 00:16:38 UTC 2011
On Mittwoch, 24. August 2011 15:28:08 Konrad Enzensberger wrote:
> Hello,
Hi Konrad,
> updating and compling current marblewidget code
> i faced curious behavior drawnig layers.
>
> 1. GraticulePlugin
>
> - starting marble with settings for Atmosphere enabled, Graticule is drawn on top of map
> - switch Amosphere off, Graticule is not visible anymore.
> - switch Amosphere on, Graticule stays not visible
>
> Graticule is only visible if starting marble with settings for Atmosphere enabled.
> If i change Garticule render position to HOVERS_ABOVE_SURFACE, Graticule is allways
> visible, regardless if Atmospherer is on/off .
Thanks for the bug report. I've opened a bug report (for you ;) on bugs.kde.org [1] for the this problem.
> 2. custom layer
> i created a custom layer, the layer simply drawing a rect on top of the map (RenderPosition is SURFACE)
> after todays update, my layer is not visible anymore
> overriding the LayerInteface::zValue() methode in my drived layer class and returning value 1.0 , my layer is back ?!
Yeah, you're supposed to pick a (hopefully) unique zValue() for your layer in order to avoid collisions with other layers. A collision occurs when two layers have the same renderPosition() *and* the same zValue(), in which case it is undefined which layer gets rendered first. IIRC the documentation mentions that.
> mystic:
> this only happens when using the OSM map, with atlas map, behaviour is like before update.
Interesting. I haven't looked into the details yet, but it sounds like the layers that are used have different zValue()s.
Greetings,
Bernhard
[1] https://bugs.kde.org/show_bug.cgi?id=280806
More information about the Marble-devel
mailing list