From cd67721c22bb75432d9bf9e034f86f95fd5b2d6c Mon Sep 17 00:00:00 2001 From: wycwyhwyq <5f20.6d9b@gmail.com> Date: Tue, 2 Aug 2022 14:11:33 +0800 Subject: [PATCH] fix v4l2_drm demo (#266) --- package/mediactl_lib/src/v4l2_drm/v4l2_drm.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/package/mediactl_lib/src/v4l2_drm/v4l2_drm.cc b/package/mediactl_lib/src/v4l2_drm/v4l2_drm.cc index b8e0bbf..d1e25f9 100644 --- a/package/mediactl_lib/src/v4l2_drm/v4l2_drm.cc +++ b/package/mediactl_lib/src/v4l2_drm/v4l2_drm.cc @@ -702,10 +702,10 @@ int video_resolution_adaptation(void) } else { return -1; } - // force 16bytes aligned + // force width 16 aligned and height 2 aligned for (int i = 0; i < 2; i++) { video_width[i] = (video_width[i] + 15) & 0xFFF0; - video_height[i] = (video_height[i] + 15) & 0xFFF0; + video_height[i] = (video_height[i] + 1) & 0xFFFE; } // force set resolution and offset (debug use) for (int i = 0; i < 2; i++) {