Skip to content
This repository has been archived by the owner on Jan 7, 2023. It is now read-only.

Commit

Permalink
Add BO_USAGE_RENDERING to YUYV/VYUY formats
Browse files Browse the repository at this point in the history
This is needed for overlay input with YUYV/VYUY formats.

Signed-off-by: Xiaosong Wei <[email protected]>
  • Loading branch information
XiaosongWei authored and kalyankondapally committed Oct 29, 2017
1 parent 0eeee78 commit 03bb0b1
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
2 changes: 1 addition & 1 deletion i915.c
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ static const uint32_t render_target_formats[] = { DRM_FORMAT_ABGR8888, DRM_FORMA

static const uint32_t tileable_texture_source_formats[] = { DRM_FORMAT_GR88, DRM_FORMAT_NV12,
DRM_FORMAT_R8, DRM_FORMAT_UYVY,
DRM_FORMAT_YUYV };
DRM_FORMAT_YUYV, DRM_FORMAT_YVYU, DRM_FORMAT_VYUY };

static const uint32_t texture_source_formats[] = { DRM_FORMAT_YVU420, DRM_FORMAT_YVU420_ANDROID };

Expand Down
8 changes: 7 additions & 1 deletion i915_private.c
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,13 @@ int i915_private_add_combinations(struct driver *drv)
drv_modify_combination(drv, DRM_FORMAT_NV12, &metadata,
BO_USE_RENDERING | BO_USE_TEXTURE | BO_USE_CAMERA_MASK);
drv_modify_combination(drv, DRM_FORMAT_YUYV, &metadata,
BO_USE_TEXTURE | BO_USE_CAMERA_MASK);
BO_USE_TEXTURE | BO_USE_CAMERA_MASK | BO_USE_RENDERING);
drv_modify_combination(drv, DRM_FORMAT_VYUY, &metadata,
BO_USE_TEXTURE | BO_USE_CAMERA_MASK | BO_USE_RENDERING);
drv_modify_combination(drv, DRM_FORMAT_UYVY, &metadata,
BO_USE_TEXTURE | BO_USE_CAMERA_MASK | BO_USE_RENDERING);
drv_modify_combination(drv, DRM_FORMAT_YVYU, &metadata,
BO_USE_TEXTURE | BO_USE_CAMERA_MASK | BO_USE_RENDERING);
drv_modify_combination(drv, DRM_FORMAT_YVU420_ANDROID, &metadata,
BO_USE_TEXTURE | BO_USE_CAMERA_MASK);

Expand Down

0 comments on commit 03bb0b1

Please sign in to comment.