From: Jiyong Date: Mon, 26 Aug 2024 06:23:17 +0000 (+0900) Subject: Bug fix. the specific src_width can't rotate as 90 or 270 X-Git-Tag: accepted/tizen/7.0/unified/20240829.011936^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fheads%2Ftizen_7.0;p=platform%2Fcore%2Fmultimedia%2Flibmm-imgp-gstcs.git Bug fix. the specific src_width can't rotate as 90 or 270 Change-Id: Ifdf21ef8a92754fbbc1d4d0c389af0a6bf4b7bb6 --- diff --git a/gstcs/mm_util_gstcs.c b/gstcs/mm_util_gstcs.c index bb2c990..d63c50e 100644 --- a/gstcs/mm_util_gstcs.c +++ b/gstcs/mm_util_gstcs.c @@ -294,7 +294,7 @@ static GstCaps* _mm_get_capabilities(mm_util_color_format_e color_format, unsign } static void _mm_get_round_up_width_height(mm_util_color_format_e color_format, unsigned int width, unsigned int height, - bool elevation_round_up_4, unsigned int *stride, unsigned int *elevation) + unsigned int *stride, unsigned int *elevation) { switch (color_format) { case MM_UTIL_COLOR_YUV420: @@ -309,10 +309,8 @@ static void _mm_get_round_up_width_height(mm_util_color_format_e color_format, u case MM_UTIL_COLOR_RGB16: case MM_UTIL_COLOR_RGB24: *stride = MM_UTIL_ROUND_UP_4(width); - if (elevation_round_up_4) - *elevation = MM_UTIL_ROUND_UP_4(height); - else - *elevation = MM_UTIL_ROUND_UP_2(height); + /* Rounding the src_width affects rounding the dst_height when rotating */ + *elevation = MM_UTIL_ROUND_UP_4(height); break; case MM_UTIL_COLOR_ARGB: case MM_UTIL_COLOR_BGRA: @@ -468,9 +466,9 @@ static int _mm_imgp_gstcs_processing(gstreamer_s* pGstreamer_s, unsigned char *s gst_object_unref(bus); _mm_get_round_up_width_height(pImgp_info->src_format, pImgp_info->src_width, pImgp_info->src_height, - (pImgp_info->angle == MM_UTIL_ROTATE_90 || pImgp_info->angle == MM_UTIL_ROTATE_270), &src_stride, &src_elevation); + &src_stride, &src_elevation); _mm_get_round_up_width_height(pImgp_info->dst_format, pImgp_info->dst_width, pImgp_info->dst_height, - false, &pImgp_info->output_stride, &pImgp_info->output_elevation); + &pImgp_info->output_stride, &pImgp_info->output_elevation); src_caps = _mm_get_capabilities(pImgp_info->src_format, src_stride, src_elevation); dst_caps = _mm_get_capabilities(pImgp_info->dst_format, pImgp_info->output_stride, pImgp_info->output_elevation); diff --git a/packaging/libmm-imgp-gstcs.spec b/packaging/libmm-imgp-gstcs.spec index 22c63c1..df0dc79 100644 --- a/packaging/libmm-imgp-gstcs.spec +++ b/packaging/libmm-imgp-gstcs.spec @@ -1,7 +1,7 @@ Name: libmm-imgp-gstcs Summary: Multimedia Framework Utility Library -Version: 0.27 -Release: 16 +Version: 0.28 +Release: 0 Group: System/Libraries License: Apache-2.0 Source0: %{name}-%{version}.tar.gz