summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDeepak Sharma <deepak.sharma@amd.com>2017-10-02 13:37:29 -0700
committerchrome-bot <chrome-bot@chromium.org>2017-10-02 20:25:37 -0700
commit4a4646a5550219de6114311c552e288cb8619840 (patch)
tree0d5753bf19653e065277e68ad52b222e3f095458
parenta1892b2800a5847525d010d6245cbcc1776c1bea (diff)
minigbm: amdgpu: Add formats R8, GR88
Add R8 and GR88 format for dma_bufs in amdgpu. Required to support native GMB video playback. If native GMB is enbaled,chrome transcodes NV12 to RGB by importing Y plane as R8 EGLImage and the UV plane as GR88 EGLImage. BUG=b:65302612 TEST=Boot Kahlee with --enable-native-gpu-memory-buffers and play youtube. Change-Id: Ifa7e50959bb5417088357a0c0aa3ac874ecf6fc9 Signed-off-by: Deepak Sharma <deepak.sharma@amd.com> Reviewed-on: https://chromium-review.googlesource.com/695850 Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
-rw-r--r--amdgpu.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/amdgpu.c b/amdgpu.c
index 1210d1f..8448968 100644
--- a/amdgpu.c
+++ b/amdgpu.c
@@ -44,7 +44,8 @@ enum {
const static uint32_t render_target_formats[] = { DRM_FORMAT_ARGB8888, DRM_FORMAT_XBGR8888,
DRM_FORMAT_XRGB8888 };
-const static uint32_t texture_source_formats[] = { DRM_FORMAT_NV21, DRM_FORMAT_NV12 };
+const static uint32_t texture_source_formats[] = { DRM_FORMAT_GR88, DRM_FORMAT_R8,
+ DRM_FORMAT_NV21, DRM_FORMAT_NV12 };
static int amdgpu_set_metadata(int fd, uint32_t handle, struct amdgpu_bo_metadata *info)
{