i965 Gen4/5: clip: correctly handle flat varyings
authorChris Forbes <chrisf@ijw.co.nz>
Sun, 7 Jul 2013 07:47:19 +0000 (19:47 +1200)
committerChris Forbes <chrisf@ijw.co.nz>
Thu, 1 Aug 2013 08:58:56 +0000 (20:58 +1200)
commitf0feb32eaf8d4b35e5c3a47ef90aa876b231ada6
tree822a6125023093b62c12693eb5b817226d2debec
parent21922cb70d0a2de23f6080c8b9c4324cba5a2fff
i965 Gen4/5: clip: correctly handle flat varyings

Previously we only gave special treatment to the builtin color varyings.
This patch adds support for arbitrary flat-shaded varyings, which is
required for GLSL 1.30.

Based on Olivier Galibert's patch from last year:
http://lists.freedesktop.org/archives/mesa-dev/2012-July/024340.html

V5: Move key.do_flat_shading to brw_clip_compile.has_flat_shading
V6: Real bools.

[V1-2]: Signed-off-by: Olivier Galibert <galibert at pobox.com>
Signed-off-by: Chris Forbes <chrisf@ijw.co.nz>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/drivers/dri/i965/brw_clip.c
src/mesa/drivers/dri/i965/brw_clip.h
src/mesa/drivers/dri/i965/brw_clip_line.c
src/mesa/drivers/dri/i965/brw_clip_tri.c
src/mesa/drivers/dri/i965/brw_clip_unfilled.c
src/mesa/drivers/dri/i965/brw_clip_util.c