i965/fs: use determine_interpolation_mode().
authorPaul Berry <stereotype441@gmail.com>
Fri, 21 Oct 2011 14:56:08 +0000 (07:56 -0700)
committerPaul Berry <stereotype441@gmail.com>
Thu, 27 Oct 2011 22:32:00 +0000 (15:32 -0700)
commitf8386a29f07c6a41c4afb99fc3ecd9f18e9151e8
tree93dfbdf111370557a2679b133b371a9aa746a784
parente04bdeae82797dbdcf6f544a997a4626fdfd4aee
i965/fs: use determine_interpolation_mode().

This patch changes how fs_visitor::emit_general_interpolation()
decides what kind of interpolation to do.  Previously, it used the
shade model to determine how to interpolate colors, and used smooth
interpolation on everything else.  Now it uses
ir_variable::determine_interpolation_mode(), so that it respects GLSL
1.30 interpolation qualifiers.

Fixes piglit tests interpolation-flat-*-smooth-{distance,fixed,vertex}
and interpolation-flat-other-flat-{distance,fixed,vertex}.

Reviewed-by: Eric Anholt <eric@anholt.net>
src/mesa/drivers/dri/i965/brw_fs.cpp