diff options
author | Paul Berry <[email protected]> | 2011-08-26 12:08:43 -0700 |
---|---|---|
committer | Paul Berry <[email protected]> | 2011-09-06 11:05:31 -0700 |
commit | 71cb82f63ab156599613f7555a62ad52d2e3dbd7 (patch) | |
tree | 71fa182af3b771c3210ae82c173af5e095e9a3f0 | |
parent | 2ef1fa6b3c8d52e059bf6ccf519c45604962b27c (diff) |
i965: clip: Change computation of nr_regs to use VUE map.
Reviewed-by: Eric Anholt <[email protected]>
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_clip.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_clip.c b/src/mesa/drivers/dri/i965/brw_clip.c index f33518bee48..8929160acd9 100644 --- a/src/mesa/drivers/dri/i965/brw_clip.c +++ b/src/mesa/drivers/dri/i965/brw_clip.c @@ -93,12 +93,12 @@ static void compile_clip_prog( struct brw_context *brw, } } - /* The vertex attributes start at a URB row-aligned offset after - * the 8-20 dword vertex header, and continue for a URB row-aligned - * length. nr_regs determines the urb_read_length from the start - * of the header to the end of the vertex data. + /* nr_regs is the number of registers filled by reading data from the VUE. + * This program accesses the entire VUE, so nr_regs needs to be the size of + * the VUE (measured in pairs, since two slots are stored in each + * register). */ - c.nr_regs = c.header_regs + (c.nr_attrs + 1) / 2; + c.nr_regs = (c.vue_map.num_slots + 1)/2; c.nr_bytes = c.nr_regs * REG_SIZE; |