highways-demo icon indicating copy to clipboard operation
highways-demo copied to clipboard

z-order sorting for roads fails

Open matkoniecz opened this issue 7 years ago • 0 comments

Expected: bridge will be marked by rendering of road outline of bridge above road below bridge

What happens: roads are rendered like on junction

layers are used correctly in OSM data

https://mapzen.com/tangram/play/?#18.25000/50.08117/19.89062

selection_005 selection_006

It seems that

        z-order:
            filter: { $zoom: {min: 14} }
            draw:
                flatlines:
                    # let roads sort themselves past zoom 14
                    order: function() { return feature.sort_rank; }
                    # but give them all the same outline
                    outline:
                        order: 352 # magic number

            bridges-tunnels:
                filter: { any: [is_bridge: true, is_tunnel: true] }
                draw:
                    flatlines:
                        outline:
                            # except bridges and tunnels, their outlines should also self-sort
                            order: function() { return feature.sort_rank; }

was supposed to handle this but it works only sometimes.

matkoniecz avatar Jun 17 '17 12:06 matkoniecz