[Mesa-dev] [PATCH] i965/draw: Use the correct buffer index for interleaved VBO sizes

Jason Ekstrand jason at jlekstrand.net
Wed May 25 04:09:48 UTC 2016


On Tue, May 24, 2016 at 7:48 PM, Kristian Høgsberg <krh at bitplanet.net>
wrote:

> On Tue, May 24, 2016 at 5:01 PM, Jason Ekstrand <jason at jlekstrand.net>
> wrote:
> > The buffer_range_* arrays are indexed by buffer index not element index.
>
> Reviewed-by: Kristian Høgsberg <krh at bitplanet.net>
>

Thanks!


> > ---
> >  src/mesa/drivers/dri/i965/brw_draw_upload.c | 6 ++++--
> >  1 file changed, 4 insertions(+), 2 deletions(-)
> >
> > diff --git a/src/mesa/drivers/dri/i965/brw_draw_upload.c
> b/src/mesa/drivers/dri/i965/brw_draw_upload.c
> > index 3349161..f4d1b2c 100644
> > --- a/src/mesa/drivers/dri/i965/brw_draw_upload.c
> > +++ b/src/mesa/drivers/dri/i965/brw_draw_upload.c
> > @@ -529,8 +529,10 @@ brw_prepare_vertices(struct brw_context *brw)
> >                input->buffer = brw->vb.enabled[k]->buffer;
> >                input->offset = glarray->Ptr - other->Ptr;
> >
> > -               buffer_range_start[k] = MIN2(buffer_range_start[k],
> start);
> > -               buffer_range_end[k] = MAX2(buffer_range_end[k], start +
> range);
> > +               buffer_range_start[input->buffer] =
> > +                  MIN2(buffer_range_start[input->buffer], start);
> > +               buffer_range_end[input->buffer] =
> > +                  MAX2(buffer_range_end[input->buffer], start + range);
> >                break;
> >             }
> >          }
> > --
> > 2.5.0.400.gff86faf
> >
> > _______________________________________________
> > mesa-dev mailing list
> > mesa-dev at lists.freedesktop.org
> > https://lists.freedesktop.org/mailman/listinfo/mesa-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20160524/5b85d2a9/attachment.html>


More information about the mesa-dev mailing list