draw/so: uses the correct index with the pre clipped coordinates
authorZack Rusin <zackr@vmware.com>
Thu, 18 Apr 2013 02:25:20 +0000 (19:25 -0700)
committerZack Rusin <zackr@vmware.com>
Thu, 18 Apr 2013 18:36:38 +0000 (11:36 -0700)
commitc1299204adc2c926b0ab089e3d49cae64688d39d
tree9b1ca80d7c1f46b563f10ba0e2d8cf17af0f3bc3
parent8b2662e900914f817615dbf8940853cec324290d
draw/so: uses the correct index with the pre clipped coordinates

pre_clip_pos is a float[4] we just used (*float)[4] to be able to
jump within the array of vertex_headers with it. So if the idx
happened to be anything but 0, we'd actually read from some garbage
in memory. Change it to just be a simple pointer instead of casting
it to something that it's not. As suggested by Jose.

Signed-off-by: Zack Rusin <zackr@vmware.com>
Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
src/gallium/auxiliary/draw/draw_pt_so_emit.c