Fix build error due to GIF_ENCODER_V2 50/142450/4 submit/tizen/20170804.071846
authorJiyong Min <jiyong.min@samsung.com>
Fri, 4 Aug 2017 03:15:39 +0000 (12:15 +0900)
committerJiyong Min <jiyong.min@samsung.com>
Fri, 4 Aug 2017 07:08:06 +0000 (16:08 +0900)
Change-Id: I43745078690359994295b0b7606db11ba3e5799f
Signed-off-by: Jiyong Min <jiyong.min@samsung.com>
packaging/capi-media-image-util.spec
src/image_util.c

index 1b70a28..7b2d49d 100755 (executable)
@@ -1,6 +1,6 @@
 Name:       capi-media-image-util
 Summary:    A Image Utility library in Tizen Native API
-Version:    0.1.22
+Version:    0.1.23
 Release:    2
 Group:      Multimedia/API
 License:    Apache-2.0
index f452830..c5907ad 100755 (executable)
@@ -1677,8 +1677,8 @@ int image_util_encode_set_resolution(image_util_encode_h handle, unsigned long w
                        }
 
                        if (!_handle->current_resolution_count) {
-                               mm_util_gif_encode_set_width(gif_data, width);
-                               mm_util_gif_encode_set_height(gif_data, height);
+                               gif_data->width = width;
+                               gif_data->height = height;
                                _handle->width = width;
                                _handle->height = height;
                        } else if ((width > gif_data->frames[0]->width) || (height > gif_data->frames[0]->height)) {
@@ -1847,7 +1847,7 @@ int image_util_encode_set_gif_frame_delay_time(image_util_encode_h handle, unsig
                _handle->image_count++;
        }
 
-       mm_util_gif_encode_set_frame_delay_time(gif_data->frames[_handle->current_delay_count], delay_time);
+       gif_data->frames[_handle->current_delay_count]->delay_time = delay_time;
        _handle->current_delay_count++;
 
        return err;
@@ -1869,7 +1869,7 @@ int image_util_encode_set_input_buffer(image_util_encode_h handle, const unsigne
 
        /* initialize buffer and value for source buffer */
        if (_handle->image_type == IMAGE_UTIL_GIF) {
-               void *tmp_buffer = NULL;
+               void **tmp_buffer = NULL;
                if (_handle->is_encoded) {
                        _image_util_encode_destroy_gif_buffer(_handle->image_h);
                        err = _image_util_encode_create_gif_buffer(_handle->image_h);
@@ -1883,7 +1883,7 @@ int image_util_encode_set_input_buffer(image_util_encode_h handle, const unsigne
                        _handle->current_resolution_count = 0;
                        _handle->current_delay_count = 0;
                }
-               tmp_buffer = (void *)realloc(_handle->src_buffer, (_handle->current_buffer_count + 1) * sizeof(void *));
+               tmp_buffer = (void **)realloc(_handle->src_buffer, (_handle->current_buffer_count + 1) * sizeof(void *));
                image_util_retvm_if((tmp_buffer == NULL), IMAGE_UTIL_ERROR_OUT_OF_MEMORY, "memory reallocation failed");
                _handle->src_buffer = tmp_buffer;
                _handle->src_buffer[_handle->current_buffer_count] = (void *)src_buffer;
@@ -2045,7 +2045,7 @@ static int _image_util_encode_internal(decode_encode_s * _handle)
                                return MM_UTIL_ERROR_INVALID_OPERATION;
                        }
 
-                       mm_util_gif_encode_set_image_count(gif_data, _handle->image_count);
+                       gif_data->image_count = _handle->image_count;
                        err = mm_util_encode_gif(gif_data);
 
                        if (err == MM_UTIL_ERROR_NONE) {