tangram-es icon indicating copy to clipboard operation
tangram-es copied to clipboard

actual transparency of polygon is half of what is specified in `color`

Open westnordost opened this issue 1 year ago • 0 comments

Have a style like this and go to 53.59579/9.94521:

sources:
    jawg:
        type: MVT
        url: https://tile.jawg.io/streets-v2/{z}/{x}/{y}.pbf
        max_zoom: 16
        url_params:
            access-token: Rqx0Qqc3TAHCG5MVXmxSAkaSgwm5nVSq4fV8IeTxiq9cieOQFfOt5BsYjK8Cwkqr
styles:
    buildings-style:
        base: polygons
        blend: translucent
layers:
    buildings:
        data: { source: jawg, layer: building }
        draw:
            buildings-style:
                order: 100
                color: rgba(0,0,0,0.25)
scene:
    background:
        color: "#ffffff"

RESULT:

You'll see this (as if alpha was 0.5):

image

EXPECTED RESULT:

image

ENVIRONMENT:

0.17.1, Android 12

MORE INFORMATION:

The bug only appears for tangram-es. Tangram (JS) does not have this bug. So if you input the above style in https://play.tangram.city/?#20.00000/53.59567/9.94527 , the transparency will be correct.

When the transparency is 0.5, the polygon will be drawn at full alpha in tangram-es.

westnordost avatar Oct 02 '22 22:10 westnordost