diff options
author | Kenneth Graunke <kenneth@whitecape.org> | 2017-04-26 14:28:49 -0700 |
---|---|---|
committer | Andres Gomez <agomez@igalia.com> | 2017-07-08 15:47:58 +0300 |
commit | cfba0e166ab7b7180392abd31c97ad8df5db6e1b (patch) | |
tree | 8dfe8c6088847f62000d5061d4e8d2e555d512b5 | |
parent | 1492237b74c54363f85e459053633c6960ca3dc5 (diff) |
i965: Use true AA line distance on G45/Ironlake.
The original Broadwater and Crestline platforms computed antialiased
line distances using "manhattan" distance, aka a + b = c. Eaglelake
and Cantiga added "true" distance, which apparently does something
like max(a, b) + min(a, b) / 4. Not exactly "true", but at least
more accurate.
The G45 documentation indicates that the old manhattan distance setting
is "only for debug purposes" and should never be used. The Ironlake
documentation no longer mentions AALINEDISTANCE_MANHATTAN, though it
does still contain the narrative about the feature.
At any rate, we should use the more accurate mode.
Reviewed-by: Plamena Manolova <plamena.manolova@intel.com>
Reviewed-by: Francisco Jerez <currojerez@riseup.net>
(cherry picked from commit b625bcc601a16fab1962f9ed569700d3d08738b9)
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_sf_state.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_sf_state.c b/src/mesa/drivers/dri/i965/brw_sf_state.c index e919f5d14b4..d50ceb12133 100644 --- a/src/mesa/drivers/dri/i965/brw_sf_state.c +++ b/src/mesa/drivers/dri/i965/brw_sf_state.c @@ -265,7 +265,7 @@ static void upload_sf_unit( struct brw_context *brw ) /* _NEW_PROGRAM | _NEW_POINT */ sf->sf7.use_point_size_state = !(ctx->VertexProgram.PointSizeEnabled || ctx->Point._Attenuated); - sf->sf7.aa_line_distance_mode = 0; + sf->sf7.aa_line_distance_mode = brw->is_g4x || brw->gen == 5; /* might be BRW_NEW_PRIMITIVE if we have to adjust pv for polygons: * _NEW_LIGHT |