diff options
author | Dave Airlie <[email protected]> | 2011-10-10 20:35:34 +0100 |
---|---|---|
committer | Dave Airlie <[email protected]> | 2011-10-10 20:53:26 +0100 |
commit | 95fd5e5aba2e21ab20cb971506a81c0049b5a694 (patch) | |
tree | d112a103a7b42cbe2f6c431b22552bdcde9e7f90 /src/gallium/drivers/r600/evergreen_state.c | |
parent | 8d3e505ed66cbaa93782acdd5b296704392fcb06 (diff) |
r600g: drop force int type workaround
now that we have integer texture types I can drop this workaround so that
copies of values is done properly (as floats would fail on some corner cases).
Signed-off-by: Dave Airlie <[email protected]>
Diffstat (limited to 'src/gallium/drivers/r600/evergreen_state.c')
-rw-r--r-- | src/gallium/drivers/r600/evergreen_state.c | 14 |
1 files changed, 3 insertions, 11 deletions
diff --git a/src/gallium/drivers/r600/evergreen_state.c b/src/gallium/drivers/r600/evergreen_state.c index bc16be7dd92..92600f8d6d6 100644 --- a/src/gallium/drivers/r600/evergreen_state.c +++ b/src/gallium/drivers/r600/evergreen_state.c @@ -1059,11 +1059,6 @@ static struct pipe_sampler_view *evergreen_create_sampler_view(struct pipe_conte endian = r600_colorformat_endian_swap(format); - if (tmp->force_int_type) { - word4 &= C_030010_NUM_FORMAT_ALL; - word4 |= S_030010_NUM_FORMAT_ALL(V_030010_SQ_NUM_FORMAT_INT); - } - height = texture->height0; depth = texture->depth0; @@ -1361,6 +1356,8 @@ static void evergreen_cb(struct r600_pipe_context *rctx, struct r600_pipe_state break; } } + + ntype = V_028C70_NUMBER_UNORM; if (desc->colorspace == UTIL_FORMAT_COLORSPACE_SRGB) ntype = V_028C70_NUMBER_SRGB; else if (desc->channel[i].type == UTIL_FORMAT_TYPE_SIGNED) { @@ -1373,8 +1370,7 @@ static void evergreen_cb(struct r600_pipe_context *rctx, struct r600_pipe_state ntype = V_028C70_NUMBER_UNORM; else if (desc->channel[i].pure_integer) ntype = V_028C70_NUMBER_UINT; - } else - ntype = V_028C70_NUMBER_UNORM; + } format = r600_translate_colorformat(surf->base.format); swap = r600_translate_colorswap(surf->base.format); @@ -1384,10 +1380,6 @@ static void evergreen_cb(struct r600_pipe_context *rctx, struct r600_pipe_state endian = r600_colorformat_endian_swap(format); } - /* disable when gallium grows int textures */ - if ((format == FMT_32_32_32_32 || format == FMT_16_16_16_16) && rtex->force_int_type) - ntype = V_028C70_NUMBER_UINT; - /* blend clamp should be set for all NORM/SRGB types */ if (ntype == V_028C70_NUMBER_UNORM || ntype == V_028C70_NUMBER_SNORM || ntype == V_028C70_NUMBER_SRGB) |