Skip to content

Commit 7e00e62

Browse files
committed
improved(display): Treat lines as solid when "strokeDasharray" is a dynamic StyleExpression and dashSize resolves to 0
Signed-off-by: Tim Deubler <tim.deubler@here.com>
1 parent c3057eb commit 7e00e62

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

packages/display/src/displays/webgl/glsl/line_fragment.glsl

+2-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@ void main(void){
2626
}
2727

2828
#ifdef DASHARRAY
29-
float dashSize = v_dashSize.x;
29+
// Ensure dashSize remains valid: if set to 0 (dynamic uniform), set to large value to force a solid line
30+
float dashSize = v_dashSize.x + (1.0 - step(0.1, v_dashSize.x)) * 1e5;
3031
float gapSize = v_dashSize.y;
3132
float totalDashSize = dashSize + gapSize;
3233

0 commit comments

Comments
 (0)