unsigned num_vtxbufs;
struct pipe_index_buffer idxbuf;
uint32_t vbo_fifo;
+ unsigned vbo_min_index; /* from pipe_draw_info, for vertex upload */
+ unsigned vbo_max_index;
struct pipe_sampler_view *textures[5][PIPE_MAX_SAMPLERS];
unsigned num_textures[5];
continue;
push = nvc0->vbo_push_hint;
if (!push) {
- nvc0_migrate_vertices(nvc0_resource(vb->buffer),
- vb->buffer_offset,
- vb->buffer->width0 - vb->buffer_offset);
+ unsigned base, size;
+ base = vb->buffer_offset + nvc0->vbo_min_index * vb->stride;
+ size = (nvc0->vbo_max_index - nvc0->vbo_min_index + 1) * vb->stride;
+ nvc0_migrate_vertices(nvc0_resource(vb->buffer), base, size);
nvc0->vbo_dirty = TRUE;
} else
continue;
!(info->indexed &&
((info->max_index - info->min_index + 64) < info->count));
+ nvc0->vbo_min_index = info->min_index;
+ nvc0->vbo_max_index = info->max_index;
+
nvc0_state_validate(nvc0);
if (nvc0->state.instance_base != info->start_instance) {