Refactoring webp-loading and loader-webp
[platform/core/uifw/dali-adaptor.git] / dali / internal / imaging / common / webp-loading.h
index f3428e6..5a232fb 100644 (file)
@@ -57,6 +57,13 @@ public:
   static AnimatedImageLoadingPtr New(const std::string& url, bool isLocalResource);
 
   /**
+   * Create a WebPLoading with the given url and resourceType.
+   * @param[in] fp The file pointer to be load.
+   * @return A newly created WebPLoading.
+   */
+  static AnimatedImageLoadingPtr New(FILE* const fp);
+
+  /**
    * @brief Constructor
    *
    * Construct a Loader with the given URL
@@ -66,21 +73,17 @@ public:
   WebPLoading(const std::string& url, bool isLocalResource);
 
   /**
-   * @brief Destructor
+   * @brief Constructor
+   *
+   * Construct a Loader with the given URL
+   * @param[in] fp The file pointer to be load.
    */
-  ~WebPLoading() override;
+  WebPLoading(FILE* const fp);
 
   /**
-   * @brief Load the next N Frames of the webp.
-   *
-   * @note This function will load the entire webp into memory if not already loaded.
-   * @param[in] frameStartIndex The frame counter to start from. Will usually be the next frame
-   * after the previous invocation of this method, or 0 to start.
-   * @param[in] count The number of frames to load
-   * @param[out] pixelData The vector in which to return the frame data
-   * @return True if the frame data was successfully loaded
+   * @brief Destructor
    */
-  bool LoadNextNFrames(uint32_t frameStartIndex, int count, std::vector<Dali::PixelData>& pixelData) override;
+  ~WebPLoading() override;
 
   /**
    * @brief Load the next Frame of the animated image.