u_vbuf: don't upload user buffers if the driver supports them
authorMarek Olšák <maraeo@gmail.com>
Thu, 19 Apr 2012 03:28:27 +0000 (05:28 +0200)
committerMarek Olšák <maraeo@gmail.com>
Mon, 23 Apr 2012 23:39:22 +0000 (01:39 +0200)
src/gallium/auxiliary/util/u_vbuf.c

index e2e0215404c39cf92b4037d837cc8d88502612ae..c25385fbf27822cbf034162e6a2918dd2d01f4f8 100644 (file)
@@ -731,7 +731,7 @@ void u_vbuf_set_vertex_buffers(struct u_vbuf *mgr, unsigned count,
          continue;
       }
 
-      if (vb->buffer->user_ptr) {
+      if (!mgr->caps.user_vertex_buffers && vb->buffer->user_ptr) {
          mgr->user_vb_mask |= 1 << i;
          pipe_resource_reference(&real_vb->buffer, NULL);
          continue;