aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorIcecream95 <[email protected]>2020-03-24 13:09:30 +1300
committerMarge Bot <[email protected]>2020-03-31 00:48:58 +0000
commit81d059c89859841bf6c4c74e29d2dd95f6dd93bf (patch)
tree77a700e17341c07f4fe60b198b0b00d86af3335d /src
parentbad6fc48712b761351bdd63e92859456a225d53e (diff)
panfrost: Add support for B5G5R5X1
Tested with texenv from mesa-demos. Reviewed-by: Alyssa Rosenzweig <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4292>
Diffstat (limited to 'src')
-rw-r--r--src/panfrost/encoder/pan_format.c3
-rw-r--r--src/panfrost/include/panfrost-job.h1
-rw-r--r--src/panfrost/pandecode/pan_pretty_print.c1
3 files changed, 5 insertions, 0 deletions
diff --git a/src/panfrost/encoder/pan_format.c b/src/panfrost/encoder/pan_format.c
index 1b8cb4faef6..26d3f7951eb 100644
--- a/src/panfrost/encoder/pan_format.c
+++ b/src/panfrost/encoder/pan_format.c
@@ -127,6 +127,9 @@ panfrost_find_format(const struct util_format_description *desc)
case PIPE_FORMAT_B5G6R5_UNORM:
return MALI_RGB565;
+ case PIPE_FORMAT_B5G5R5X1_UNORM:
+ return MALI_RGB5_X1_UNORM;
+
case PIPE_FORMAT_B5G5R5A1_UNORM:
return MALI_RGB5_A1_UNORM;
diff --git a/src/panfrost/include/panfrost-job.h b/src/panfrost/include/panfrost-job.h
index 4f1edeb8453..355eca9491a 100644
--- a/src/panfrost/include/panfrost-job.h
+++ b/src/panfrost/include/panfrost-job.h
@@ -287,6 +287,7 @@ enum mali_format {
MALI_ASTC_HDR_SUPP = MALI_FORMAT_COMPRESSED | 0x17,
MALI_RGB565 = MALI_FORMAT_SPECIAL | 0x0,
+ MALI_RGB5_X1_UNORM = MALI_FORMAT_SPECIAL | 0x1,
MALI_RGB5_A1_UNORM = MALI_FORMAT_SPECIAL | 0x2,
MALI_RGB10_A2_UNORM = MALI_FORMAT_SPECIAL | 0x3,
MALI_RGB10_A2_SNORM = MALI_FORMAT_SPECIAL | 0x5,
diff --git a/src/panfrost/pandecode/pan_pretty_print.c b/src/panfrost/pandecode/pan_pretty_print.c
index e0f00541f8a..9f9852a7917 100644
--- a/src/panfrost/pandecode/pan_pretty_print.c
+++ b/src/panfrost/pandecode/pan_pretty_print.c
@@ -46,6 +46,7 @@ char *pandecode_format(enum mali_format format)
DEFINE_CASE(ASTC_SRGB_SUPP);
DEFINE_CASE(ASTC_HDR_SUPP);
DEFINE_CASE(RGB565);
+ DEFINE_CASE(RGB5_X1_UNORM);
DEFINE_CASE(RGB5_A1_UNORM);
DEFINE_CASE(RGB10_A2_UNORM);
DEFINE_CASE(RGB10_A2_SNORM);