It's valid to have a vertex buffer with a NULL resource. Signed-off-by: Rhys Perry <pendingchao...@gmail.com> --- src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c | 4 ++++ 1 file changed, 4 insertions(+)
diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c b/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c index 66de6d9e2f..7871d50ab9 100644 --- a/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c +++ b/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c @@ -346,6 +346,10 @@ nvc0_validate_vertex_buffers(struct nvc0_context *nvc0) /* address/value set in nvc0_update_user_vbufs */ continue; } + if (!vb->buffer.resource) { + IMMED_NVC0(push, NVC0_3D(VERTEX_ARRAY_FETCH(i)), 0); + continue; + } res = nv04_resource(vb->buffer.resource); offset = ve->pipe.src_offset + vb->buffer_offset; limit = vb->buffer.resource->width0 - 1; -- 2.17.1 _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev