r600g: fix up the rules for enabling SOURCE_FORMAT(EXPORT_NORM)
authorAlex Deucher <alexdeucher@gmail.com>
Thu, 5 May 2011 22:54:03 +0000 (18:54 -0400)
committerAlex Deucher <alexdeucher@gmail.com>
Thu, 5 May 2011 22:54:03 +0000 (18:54 -0400)
commit5939bc03bc15b9b1131463ffad04a7b2d987074d
tree36bebb81a4c618f65ee589b72cabb08744c9d292
parentbf7a3ddca6fcc73eebdd9afdc45a485b38477bd9
r600g: fix up the rules for enabling SOURCE_FORMAT(EXPORT_NORM)

Setting SOURCE_FORMAT to EXPORT_NORM is an optimization.
Leaving SOURCE_FORMAT at 0 will work in all cases, but is less
efficient.  The conditions for the setting the EXPORT_NORM
optimization are as follows:

R600/RV6xx:
BLEND_CLAMP is enabled
BLEND_FLOAT32 is disabled
11-bit or smaller UNORM/SNORM/SRGB

R7xx/evergreen:
11-bit or smaller UNORM/SNORM/SRGB
16-bit or smaller FLOAT

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
src/gallium/drivers/r600/evergreen_state.c
src/gallium/drivers/r600/r600_state.c