[4.0] Fixed loading of compressed texture formats
[platform/core/uifw/dali-adaptor.git] / platform-abstractions / tizen / image-loaders / loader-gif.h
index b3a3699..e637ac1 100644 (file)
@@ -2,7 +2,7 @@
 #define __DALI_TIZEN_PLATFORM_LOADER_GIF_H__
 
 /*
- * Copyright (c) 2014 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2017 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
  */
 
 #include <cstdio>
+#include "image-loader-input.h"
 
 namespace Dali
 {
-
-namespace Integration
+namespace Devel
 {
-  class Bitmap;
+class PixelBuffer;
 }
 
-struct ImageAttributes;
 
 namespace TizenPlatform
 {
@@ -45,12 +44,11 @@ const unsigned char MAGIC_BYTE_2 = 0x49;
  * Loads the bitmap from a GIF file.  This function checks the header first
  * and if it is not a GIF file, then it returns straight away.
  * @note For animated GIFs, only the first image is displayed
- * @param[in]  fp      Pointer to the Image file
- * @param[in]  bitmap  The bitmap class where the decoded image will be stored
- * @param[in]  attributes  Describes the dimensions, pixel format and other details for loading the image data
+ * @param[in]  input  Information about the input image (including file pointer)
+ * @param[out] bitmap The bitmap class where the decoded image will be stored
  * @return  true if file decoded successfully, false otherwise
  */
-bool LoadBitmapFromGif( FILE *fp, Integration::Bitmap& bitmap, ImageAttributes& attributes, const ResourceLoadingClient& client );
+bool LoadBitmapFromGif( const ImageLoader::Input& input, Dali::Devel::PixelBuffer& bitmap );
 
 /**
  * Loads the header of a GIF file and fills in the width and height appropriately.
@@ -60,7 +58,7 @@ bool LoadBitmapFromGif( FILE *fp, Integration::Bitmap& bitmap, ImageAttributes&
  * @param[in/out]  height  Is set with the height of the image
  * @return true if the file's header was read successully, false otherwise
  */
-bool LoadGifHeader(FILE *fp, const ImageAttributes& attributes, unsigned int &width, unsigned int &height );
+bool LoadGifHeader( const ImageLoader::Input& input, unsigned int& width, unsigned int& height );
 
 } // namespace TizenPlatform