zink: clamp line_stipple_factor to 1 if stipple is disabled
authorMike Blumenkrantz <michael.blumenkrantz@gmail.com>
Wed, 12 Oct 2022 17:42:58 +0000 (13:42 -0400)
committerMarge Bot <emma+marge@anholt.net>
Fri, 14 Oct 2022 01:16:30 +0000 (01:16 +0000)
0 is technically an illegal value even though it won't be read in this case

cc: mesa-stable

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19065>

src/gallium/drivers/zink/zink_state.c

index 99628d8..a4f362f 100644 (file)
@@ -616,7 +616,7 @@ zink_create_rasterizer_state(struct pipe_context *pctx,
    }
 
    if (!rs_state->line_stipple_enable) {
-      state->base.line_stipple_factor = 0;
+      state->base.line_stipple_factor = 1;
       state->base.line_stipple_pattern = UINT16_MAX;
    }