summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRussell King <rmk@armlinux.org.uk>2017-02-04 12:47:10 +0000
committerRussell King <rmk@armlinux.org.uk>2017-02-05 19:27:36 +0000
commit640a6598dfe61eca4c457a1c69eebca6a3e0e534 (patch)
treec2663eb15407b537fb17eac60ffeb0f21f64c850
parentd82c89d5d3b05e333d9caef5ddb7ea7ba3f5a524 (diff)
etnaviv: add xrgb8888 Xv format
Add XRGB8888 Xv format, which speeds up rendering from the gstreamer bayer2rgb plugin, as it avoids gstreamer having to convert XRGB to YUV. Signed-off-by: Russell King <rmk@armlinux.org.uk>
-rw-r--r--etnaviv/etnaviv_xv.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/etnaviv/etnaviv_xv.c b/etnaviv/etnaviv_xv.c
index 7b5ab67..f11521d 100644
--- a/etnaviv/etnaviv_xv.c
+++ b/etnaviv/etnaviv_xv.c
@@ -73,6 +73,12 @@ static XF86VideoFormatRec etnaviv_formats[] = {
},
};
+static const struct etnaviv_format fmt_xrgb8888 = {
+ .format = DE_FORMAT_X8R8G8B8,
+ .swizzle = DE_SWIZZLE_ARGB,
+ .planes = 1,
+};
+
static const struct etnaviv_format fmt_uyvy = {
.format = DE_FORMAT_UYVY,
.swizzle = DE_SWIZZLE_ARGB,
@@ -115,6 +121,9 @@ static const struct xv_image_format etnaviv_image_formats[] = {
.u.data = &fmt_i420,
.xv_image = XVIMAGE_I420,
}, {
+ .u.data = &fmt_xrgb8888,
+ .xv_image = XVIMAGE_XRGB8888,
+ }, {
.u.data = NULL,
.xv_image = XVIMAGE_XVBO,
},