aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJonathan Marek <[email protected]>2019-12-09 10:31:47 -0500
committerJonathan Marek <[email protected]>2020-01-05 17:04:39 +0000
commit680d8069509c7043416d2eb95f098a89dceabf49 (patch)
treeb58f7816baf57ced5b2068518db72898e79a06b6
parentc5ae64ebc716267f752fc530028791363148f25c (diff)
etnaviv: fix incorrectly failing vertex size assert
Changes the assert to match the comment above. This assert was failing in some cases while running darkplaces. Signed-off-by: Jonathan Marek <[email protected]> Reviewed-by: Christian Gmeiner <[email protected]>
-rw-r--r--src/gallium/drivers/etnaviv/etnaviv_state.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gallium/drivers/etnaviv/etnaviv_state.c b/src/gallium/drivers/etnaviv/etnaviv_state.c
index cf44a7ea124..67f9512f74e 100644
--- a/src/gallium/drivers/etnaviv/etnaviv_state.c
+++ b/src/gallium/drivers/etnaviv/etnaviv_state.c
@@ -574,7 +574,7 @@ etna_vertex_elements_state_create(struct pipe_context *pctx,
start_offset = elements[idx].src_offset;
/* maximum vertex size is 256 bytes */
- assert(element_size != 0 && end_offset <= 256);
+ assert(element_size != 0 && (end_offset - start_offset) < 256);
/* check whether next element is consecutive to this one */
nonconsecutive = (idx == (num_elements - 1)) ||