diff options
author | Nicolai Hähnle <[email protected]> | 2017-10-03 15:02:22 +0200 |
---|---|---|
committer | Nicolai Hähnle <[email protected]> | 2017-10-12 08:42:55 +0200 |
commit | bc2d87410169c0f0eee19070ea8167d481861eb4 (patch) | |
tree | b8d50a7d66c83130dd9e83fb9d18a82bc36337b3 /src/gallium/drivers/radeonsi | |
parent | 9f55da130e8aedb507edbf0674d1e5b4e1c101ad (diff) |
radeonsi: add support for PIPE_FORMAT_{X1,A1}R5G5B5_UNORM
Fixes dEQP-EGL.functional.image.modify.tex_rgb5_a1_tex_subimage_rgba8
Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/gallium/drivers/radeonsi')
-rw-r--r-- | src/gallium/drivers/radeonsi/si_state.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/gallium/drivers/radeonsi/si_state.c b/src/gallium/drivers/radeonsi/si_state.c index 4bfd5272db0..ae45e1a6b26 100644 --- a/src/gallium/drivers/radeonsi/si_state.c +++ b/src/gallium/drivers/radeonsi/si_state.c @@ -1506,6 +1506,8 @@ static uint32_t si_translate_colorformat(enum pipe_format format) } } else if (HAS_SIZE(5,5,5,1)) { return V_028C70_COLOR_1_5_5_5; + } else if (HAS_SIZE(1,5,5,5)) { + return V_028C70_COLOR_5_5_5_1; } else if (HAS_SIZE(10,10,10,2)) { return V_028C70_COLOR_2_10_10_10; } @@ -1764,6 +1766,12 @@ static uint32_t si_translate_texformat(struct pipe_screen *screen, desc->channel[3].size == 1) { return V_008F14_IMG_DATA_FORMAT_1_5_5_5; } + if (desc->channel[0].size == 1 && + desc->channel[1].size == 5 && + desc->channel[2].size == 5 && + desc->channel[3].size == 5) { + return V_008F14_IMG_DATA_FORMAT_5_5_5_1; + } if (desc->channel[0].size == 10 && desc->channel[1].size == 10 && desc->channel[2].size == 10 && |