diff options
author | Paul Cercueil <[email protected]> | 2019-11-19 21:59:07 +0100 |
---|---|---|
committer | Marge Bot <[email protected]> | 2019-12-21 18:29:30 +0000 |
commit | 18a8c3f7f11307b348f72c64603b5761c0ce406f (patch) | |
tree | a177454428ef4e919155713572396c72073e2b00 /src/gallium | |
parent | 88d041a6b9958f893312bfd159372c4b4559652a (diff) |
u_vbuf: Only create driver CSO if no incompatible elements
Signed-off-by: Paul Cercueil <[email protected]>
Reviewed-by: Marek Olšák <[email protected]>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/2807>
Diffstat (limited to 'src/gallium')
-rw-r--r-- | src/gallium/auxiliary/util/u_vbuf.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/gallium/auxiliary/util/u_vbuf.c b/src/gallium/auxiliary/util/u_vbuf.c index 67c82a56ecd..8e67cd965f8 100644 --- a/src/gallium/auxiliary/util/u_vbuf.c +++ b/src/gallium/auxiliary/util/u_vbuf.c @@ -811,8 +811,12 @@ u_vbuf_create_vertex_elements(struct u_vbuf *mgr, unsigned count, } } - ve->driver_cso = - pipe->create_vertex_elements_state(pipe, count, driver_attribs); + /* Only create driver CSO if no incompatible elements */ + if (!ve->incompatible_elem_mask) { + ve->driver_cso = + pipe->create_vertex_elements_state(pipe, count, driver_attribs); + } + return ve; } |