Skip to contentSkip to conversation

drm/fourcc: Add formats R8, RG88, GR88

PATCH Applied Chad Versace 3 participants 3 messages Jul 9, 2015

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/fourcc: Add formats R8, RG88, GR88

The Kodi/XBMC developers want to transcode NV12 to RGB with OpenGL shaders, importing the two source planes through EGL_EXT_image_dma_buf_import. That requires importing the Y plane as an R8 EGLImage and the UV plane as either an RG88 or GR88 EGLImage.

CC Peter Frühberger <[email protected]>
Cc Rainer Hochecker <[email protected]>
Cc Benjamin Widawsky <[email protected]>

---

I recently sent a patch series to mesa-dev that uses these new formats:
Subject: [PATCH 0/2] egl,i965: Support importing R8 and GR88 dma_bufs as textures
Date: Thu, 9 Jul 2015 01:17:41 -0700

 include/uapi/drm/drm_fourcc.h | 7 +++++++
 1 file changed, 7 insertions(+)
include/uapi/drm/drm_fourcc.h +7 -0
index 2f295cd..8c5e8b9 100644
@@ -34,6 +34,13 @@
 /* color index */
 #define DRM_FORMAT_C8		fourcc_code('C', '8', ' ', ' ') /* [7:0] C */
 
+/* 8 bpp Red */
+#define DRM_FORMAT_R8		fourcc_code('R', '8', ' ', ' ') /* [7:0] R */
+
+/* 16 bpp RG */
+#define DRM_FORMAT_RG88		fourcc_code('R', 'G', '8', '8') /* [15:0] R:G 8:8 little endian */
+#define DRM_FORMAT_GR88		fourcc_code('G', 'R', '8', '8') /* [15:0] G:R 8:8 little endian */
+
 /* 8 bpp RGB */
 #define DRM_FORMAT_RGB332	fourcc_code('R', 'G', 'B', '8') /* [7:0] R:G:B 3:3:2 */
 #define DRM_FORMAT_BGR233	fourcc_code('B', 'G', 'R', '8') /* [7:0] B:G:R 2:3:3 */
Signature · 6 lines
2.5.0.rc1

_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel
Reviewed-by on v1 1/1
#1 lore raw
Quoted 27 lines · On Thu, 9 Jul 2015 01:38:42 -0700 Chad Versace <[email protected]> wrote:

The Kodi/XBMC developers want to transcode NV12 to RGB with OpenGL shaders, importing the two source planes through EGL_EXT_image_dma_buf_import. That requires importing the Y plane as an R8 EGLImage and the UV plane as either an RG88 or GR88 EGLImage.

CC Peter Frühberger <[email protected]>
Cc Rainer Hochecker <[email protected]>
Cc Benjamin Widawsky <[email protected]>

---

I recently sent a patch series to mesa-dev that uses these new formats:
Subject: [PATCH 0/2] egl,i965: Support importing R8 and GR88 dma_bufs as textures
Date: Thu, 9 Jul 2015 01:17:41 -0700

 include/uapi/drm/drm_fourcc.h | 7 +++++++
 1 file changed, 7 insertions(+)
include/uapi/drm/drm_fourcc.h +0 -0
index 2f295cd..8c5e8b9 100644
@@ -34,6 +34,13 @@
 /* color index */
 #define DRM_FORMAT_C8		fourcc_code('C', '8', ' ', ' ') /* [7:0] C */
 

include/uapi/drm/drm_fourcc.h line 46

Quoted 10 lines
include/uapi/drm/drm_fourcc.h +7 -0
+/* 8 bpp Red */
+#define DRM_FORMAT_R8		fourcc_code('R', '8', ' ', ' ') /* [7:0] R */
+
+/* 16 bpp RG */
+#define DRM_FORMAT_RG88		fourcc_code('R', 'G', '8', '8') /* [15:0] R:G 8:8 little endian */
+#define DRM_FORMAT_GR88		fourcc_code('G', 'R', '8', '8') /* [15:0] G:R 8:8 little endian */
+
 /* 8 bpp RGB */
 #define DRM_FORMAT_RGB332	fourcc_code('R', 'G', 'B', '8') /* [7:0] R:G:B 3:3:2 */
 #define DRM_FORMAT_BGR233	fourcc_code('B', 'G', 'R', '8') /* [7:0] B:G:R 2:3:3 */

Thanks,
pq
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel

#2 lore raw
Quoted 30 lines · Pekka Paalanen
Quoted 27 lines · On Thu, 9 Jul 2015 01:38:42 -0700 Chad Versace <[email protected]> wrote:

The Kodi/XBMC developers want to transcode NV12 to RGB with OpenGL shaders, importing the two source planes through EGL_EXT_image_dma_buf_import. That requires importing the Y plane as an R8 EGLImage and the UV plane as either an RG88 or GR88 EGLImage.

CC Peter Frühberger <[email protected]>
Cc Rainer Hochecker <[email protected]>
Cc Benjamin Widawsky <[email protected]>

---

I recently sent a patch series to mesa-dev that uses these new formats:
Subject: [PATCH 0/2] egl,i965: Support importing R8 and GR88 dma_bufs as textures
Date: Thu, 9 Jul 2015 01:17:41 -0700

 include/uapi/drm/drm_fourcc.h | 7 +++++++
 1 file changed, 7 insertions(+)
include/uapi/drm/drm_fourcc.h +0 -0
index 2f295cd..8c5e8b9 100644
@@ -34,6 +34,13 @@
 /* color index */
 #define DRM_FORMAT_C8		fourcc_code('C', '8', ' ', ' ') /* [7:0] C */
 
Quoted 12 lines

include/uapi/drm/drm_fourcc.h line 46

Quoted 10 lines
include/uapi/drm/drm_fourcc.h +7 -0
+/* 8 bpp Red */
+#define DRM_FORMAT_R8		fourcc_code('R', '8', ' ', ' ') /* [7:0] R */
+
+/* 16 bpp RG */
+#define DRM_FORMAT_RG88		fourcc_code('R', 'G', '8', '8') /* [15:0] R:G 8:8 little endian */
+#define DRM_FORMAT_GR88		fourcc_code('G', 'R', '8', '8') /* [15:0] G:R 8:8 little endian */
+
 /* 8 bpp RGB */
 #define DRM_FORMAT_RGB332	fourcc_code('R', 'G', 'B', '8') /* [7:0] R:G:B 3:3:2 */
 #define DRM_FORMAT_BGR233	fourcc_code('B', 'G', 'R', '8') /* [7:0] B:G:R 2:3:3 */

Applied to topic/drm-misc, thanks.
-Daniel

Quoted 8 lines

Thanks,
pq
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel

Signature · 7 lines
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel