From: Nibha Sharma Date: Tue, 13 Apr 2021 12:27:46 +0000 (+0530) Subject: [ITC][image-util][ACR-1623][New heif enum addition] X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f993f2c5c3663989abc1678b38f206b88f909d7f;p=test%2Ftct%2Fnative%2Fapi.git [ITC][image-util][ACR-1623][New heif enum addition] Change-Id: I3be2c7ad588a5ef8ee67159251f1e828b3134a2b Signed-off-by: Nibha Sharma --- diff --git a/scripts_tpk/spec.sh b/scripts_tpk/spec.sh index 31c9b4989..4522cab93 100755 --- a/scripts_tpk/spec.sh +++ b/scripts_tpk/spec.sh @@ -250,6 +250,7 @@ case "$1" in cp sample.gif $APP_DATA_DIR/sample.gif cp sample.png $APP_DATA_DIR/sample.png cp sample.bmp $APP_DATA_DIR/sample.bmp + cp sample.heic $APP_DATA_DIR/sample.heic chown -R 5000:5000 $APP_DATA_DIR cp res/sample_anim1.png $APP_DATA_DIR/sample_anim1.png cp res/sample_anim2.png $APP_DATA_DIR/sample_anim2.png diff --git a/src/itc/image-util/ITs-image-util-agif-encode.c b/src/itc/image-util/ITs-image-util-agif-encode.c old mode 100644 new mode 100755 index afb60eb61..b72529ccc --- a/src/itc/image-util/ITs-image-util-agif-encode.c +++ b/src/itc/image-util/ITs-image-util-agif-encode.c @@ -122,7 +122,7 @@ int ITc_image_util_agif_encode_add_frame_p(void) CHECK_HANDLE(dstHandle,"image_util_decode_create"); nRet = image_util_decode_set_input_path(dstHandle, pPath); - PRINT_RESULT_CLEANUP(IMAGE_UTIL_ERROR_NONE, nRet, "image_util_decode_set_input_buffer", ImageUtilGetError(nRet), image_util_decode_destroy(dstHandle)); + PRINT_RESULT_CLEANUP(IMAGE_UTIL_ERROR_NONE, nRet, "image_util_decode_set_input_path", ImageUtilGetError(nRet), image_util_decode_destroy(dstHandle)); nRet = image_util_decode_run2(dstHandle, &stDecodedImage); PRINT_RESULT_CLEANUP(IMAGE_UTIL_ERROR_NONE, nRet, "image_util_decode_run2", ImageUtilGetError(nRet), image_util_decode_destroy(dstHandle)); diff --git a/src/itc/image-util/ITs-image-util-common.h b/src/itc/image-util/ITs-image-util-common.h index f9cdbb631..adf1af7f1 100755 --- a/src/itc/image-util/ITs-image-util-common.h +++ b/src/itc/image-util/ITs-image-util-common.h @@ -25,6 +25,7 @@ #include #include #include +#include /** @addtogroup itc-image-util * @ingroup itc @@ -41,6 +42,7 @@ #define SAMPLE_PNG_FILE_PATH "sample.png" #define SAMPLE_GIF_FILE_PATH "sample.gif" #define SAMPLE_BMP_FILE_PATH "sample.bmp" +#define SAMPLE_HEIF_FILE_PATH "sample.heic" #define QUALITY 100 #define X 5 diff --git a/src/itc/image-util/ITs-image-util.c b/src/itc/image-util/ITs-image-util.c index 266108a00..e6ff462cd 100755 --- a/src/itc/image-util/ITs-image-util.c +++ b/src/itc/image-util/ITs-image-util.c @@ -656,7 +656,7 @@ int ITc_image_util_extract_color_from_memory_p(void) CHECK_HANDLE(dstHandle,"image_util_decode_create"); nRet = image_util_decode_set_input_path(dstHandle, pPath); - PRINT_RESULT_CLEANUP(IMAGE_UTIL_ERROR_NONE, nRet, "image_util_decode_set_input_buffer", ImageUtilGetError(nRet), image_util_decode_destroy(dstHandle)); + PRINT_RESULT_CLEANUP(IMAGE_UTIL_ERROR_NONE, nRet, "image_util_decode_set_input_path", ImageUtilGetError(nRet), image_util_decode_destroy(dstHandle)); nRet = image_util_decode_set_colorspace(dstHandle, IMAGE_UTIL_COLORSPACE_RGB888); PRINT_RESULT_CLEANUP(IMAGE_UTIL_ERROR_NONE, nRet, "image_util_decode_set_colorspace", ImageUtilGetError(nRet), image_util_decode_destroy(dstHandle)); @@ -735,23 +735,35 @@ int ITc_image_util_decode_set_input_path_p(void) START_TEST; image_util_decode_h stHandle = NULL; - int nRet = image_util_decode_create(&stHandle); - PRINT_RESULT(IMAGE_UTIL_ERROR_NONE, nRet, "image_util_decode_create", ImageUtilGetError(nRet)); - CHECK_HANDLE(stHandle,"image_util_decode_create"); - - char pPath[PATH_LEN] = {0,}; - if ( false == ImageUtilAppendToAppDataPath(SAMPLE_FILE_PATH, pPath) ) + char *eImageUtilType[5] = { + "Image_01.jpg", + "sample.png", + "sample.gif", + "sample.bmp", + "sample.heic" + }; + int enum_size = 5; + int enum_counter = 0; + for(enum_counter = 0;enum_counter