diff options
author | minje.ahn <minje.ahn@samsung.com> | 2022-08-30 14:43:41 +0900 |
---|---|---|
committer | minje.ahn <minje.ahn@samsung.com> | 2022-08-30 14:43:41 +0900 |
commit | 8a1fc3d31f8380e24156f17e5401b3cecf32ad6e (patch) | |
tree | 73683df000ce46a8df27ff3b8cbee039104645c6 | |
parent | 1d08b9f9867aa29c17ab380f9722d1e32ac8513b (diff) | |
download | libmedia-thumbnail-8a1fc3d31f8380e24156f17e5401b3cecf32ad6e.tar.gz libmedia-thumbnail-8a1fc3d31f8380e24156f17e5401b3cecf32ad6e.tar.bz2 libmedia-thumbnail-8a1fc3d31f8380e24156f17e5401b3cecf32ad6e.zip |
Remove unused parametersubmit/tizen/20220830.232907accepted/tizen/unified/20220831.023433
Change-Id: I2b50e137ff17fbbb189a0ebad3aec432765a7be0
Signed-off-by: minje.ahn <minje.ahn@samsung.com>
-rwxr-xr-x | include/media-thumbnail.h | 2 | ||||
-rw-r--r-- | packaging/libmedia-thumbnail.spec | 2 | ||||
-rwxr-xr-x | src/media-thumbnail.c | 20 |
3 files changed, 5 insertions, 19 deletions
diff --git a/include/media-thumbnail.h b/include/media-thumbnail.h index 3e6dc84..e3f4d5d 100755 --- a/include/media-thumbnail.h +++ b/include/media-thumbnail.h @@ -34,7 +34,7 @@ extern "C" { #define THUMB_STRING_VALID(str) ((str != NULL && strlen(str) > 0) ? true : false) int create_video_thumbnail_to_file(const char *path, unsigned int width, unsigned int height, const char *thumb_path, bool auto_rotate); -int create_video_thumbnail_to_buffer(const char *path, unsigned int width, unsigned int height, unsigned char **thumb_buffer, size_t *thumb_size, unsigned int *thumb_width, unsigned int *thumb_height, bool auto_rotate, bool is_server_request); +int create_video_thumbnail_to_buffer(const char *path, unsigned int width, unsigned int height, unsigned char **thumb_buffer, size_t *thumb_size, unsigned int *thumb_width, unsigned int *thumb_height, bool auto_rotate); int create_image_thumbnail_to_file(const char *path, unsigned int width, unsigned int height, const char *thumb_path, bool auto_rotate); int create_image_thumbnail_to_buffer(const char *path, unsigned int width, unsigned int height, unsigned char **thumb_buffer, size_t *thumb_size, unsigned int *thumb_width, unsigned int *thumb_height); diff --git a/packaging/libmedia-thumbnail.spec b/packaging/libmedia-thumbnail.spec index 92c04a3..66ae0a6 100644 --- a/packaging/libmedia-thumbnail.spec +++ b/packaging/libmedia-thumbnail.spec @@ -1,6 +1,6 @@ Name: libmedia-thumbnail Summary: Media thumbnail service library for multimedia applications -Version: 0.4.0 +Version: 0.4.1 Release: 0 Group: Multimedia/Libraries License: Apache-2.0 diff --git a/src/media-thumbnail.c b/src/media-thumbnail.c index fdce8b0..6246a23 100755 --- a/src/media-thumbnail.c +++ b/src/media-thumbnail.c @@ -358,8 +358,7 @@ int create_video_thumbnail_to_buffer(const char *path, size_t *thumb_size, unsigned int *thumb_width, unsigned int *thumb_height, - bool auto_rotate, - bool is_server_request) + bool auto_rotate) { int err = MS_MEDIA_ERR_NONE; int video_track_num = 0; @@ -369,7 +368,6 @@ int create_video_thumbnail_to_buffer(const char *path, size_t frame_size = 0; mm_util_image_h img = NULL; mm_util_rotate_type_e rot_type = MM_UTIL_ROTATE_NUM; - mm_util_image_h convert_img = NULL; err = __check_parameter_validity_for_buffer(path, width, height, thumb_buffer, thumb_size, thumb_width, thumb_height); thumb_retvm_if(err != MS_MEDIA_ERR_NONE, err, "Invalid parameter"); @@ -388,20 +386,8 @@ int create_video_thumbnail_to_buffer(const char *path, if (err != MS_MEDIA_ERR_NONE) return err; - if (is_server_request) { - err = mm_util_convert_B_B(img, MM_UTIL_COLOR_BGRA, &convert_img); - mm_image_destroy_image(img); - if (err != MM_UTIL_ERROR_NONE) { - thumb_err("mm_util_convert_B_B failed"); - return MS_MEDIA_ERR_INTERNAL; - } - - err = mm_image_get_image(convert_img, thumb_width, thumb_height, NULL, thumb_buffer, thumb_size); - mm_image_destroy_image(convert_img); - } else { - err = mm_image_get_image(img, thumb_width, thumb_height, NULL, thumb_buffer, thumb_size); - mm_image_destroy_image(img); - } + err = mm_image_get_image(img, thumb_width, thumb_height, NULL, thumb_buffer, thumb_size); + mm_image_destroy_image(img); return err; } |