summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChangyeon Lee <cyeon.lee@samsung.com>2023-08-02 18:43:47 +0900
committerChangyeon Lee <cyeon.lee@samsung.com>2023-08-02 18:43:47 +0900
commite4ae90ad5fd7a7c1d2a03b4641dc556bd7b348d6 (patch)
tree237bc2cde7ff3344b96fc63aef4df4f189b0ce71
parent9cec27924e6a9b95d757747699fa2b099f203f62 (diff)
downloadlibtbm-dumb-e4ae90ad5fd7a7c1d2a03b4641dc556bd7b348d6.tar.gz
libtbm-dumb-e4ae90ad5fd7a7c1d2a03b4641dc556bd7b348d6.tar.bz2
libtbm-dumb-e4ae90ad5fd7a7c1d2a03b4641dc556bd7b348d6.zip
Fix stride of 4:2:2 YUV formataccepted/tizen/unified/20230803.174825
YUYV, YVYU, UYVY, VYUY format each four bytes is two pixels Change-Id: Icebe4ccb49a312617be8ca7c155c0899fbe05bdf
-rw-r--r--src/tbm_backend_dumb.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/tbm_backend_dumb.c b/src/tbm_backend_dumb.c
index 6680e7a..ad38ca9 100644
--- a/src/tbm_backend_dumb.c
+++ b/src/tbm_backend_dumb.c
@@ -447,6 +447,12 @@ tbm_dumb_bufmgr_get_plane_data(hal_tbm_bufmgr *bufmgr,
case HAL_TBM_FORMAT_YVYU:
case HAL_TBM_FORMAT_UYVY:
case HAL_TBM_FORMAT_VYUY:
+ bpp = 16;
+ _offset = 0;
+ _pitch = SIZE_ALIGN((width * bpp)>>3, TBM_SURFACE_ALIGNMENT_PITCH_YUV);
+ _size = SIZE_ALIGN(_pitch * height, TBM_SURFACE_ALIGNMENT_PLANE);
+ _bo_idx = 0;
+ break;
case HAL_TBM_FORMAT_AYUV:
bpp = 32;
_offset = 0;