-/**
- * @brief Get the size of a gif image.
- *
- * This function will read the header info from file on disk.
- *
- * @param [in] url The URL of the gif file.
- * @return The width and height in pixels of the gif image.
- */
-DALI_IMPORT_API ImageDimensions GetGifImageSize( const std::string& url );
+ static std::unique_ptr<GifLoading> New( const std::string& url );
+
+ /**
+ * @brief Constructor
+ *
+ * Construct a Loader with the given URL
+ * @param[in] url The url of the gif image to load
+ */
+ GifLoading( const std::string& url );
+
+ /**
+ * @brief Destructor
+ */
+ ~GifLoading();
+
+ /**
+ * @brief Load the next N Frames of the gif.
+ *
+ * @note This function will load the entire gif 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
+ */
+ bool LoadNextNFrames( int frameStartIndex, int count, std::vector<Dali::PixelData>& pixelData );
+
+ /**
+ * @brief Load all frames of an animated gif file.
+ *
+ * @note This function will load the entire gif into memory if not already loaded.
+ *
+ * @param[out] pixelData The loaded pixel data for each frame.
+ * @param[out] frameDelays The loaded delay time for each frame.
+ *
+ * @return True if the loading succeeded, false otherwise.
+ */
+ bool LoadAllFrames( std::vector<Dali::PixelData>& pixelData, Dali::Vector<uint32_t>& frameDelays );
+
+ /**
+ * @brief Get the size of a gif image.
+ *
+ * @note This function will load the entire gif into memory if not already loaded.
+ *
+ * @return The width and height in pixels of the gif image.
+ */
+ ImageDimensions GetImageSize();
+
+ /**
+ * @brief Get the number of frames in this gif.
+ *
+ * @note This function will load the entire gif into memory if not already loaded.
+ */
+ int GetImageCount();
+
+ /**
+ * @brief Load the frame delay counts into the provided array.
+ *
+ * @note This function will load the entire gif into memory if not already loaded.
+ * @param[in] frameDelays a vector to write the frame delays into
+ * @return true if the frame delays were successfully loaded
+ */
+ bool LoadFrameDelays( Dali::Vector<uint32_t>& frameDelays );
+
+private:
+ struct Impl;
+ Impl* mImpl;
+};