#define DALI_TOOLKIT_DEVEL_API_IMAGE_LOADER_ASYNC_IMAGE_LOADER_DEVEL_H
/*
- * Copyright (c) 2019 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2020 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.
* limitations under the License.
*/
+// EXTERNAL HEADER
#include <dali/public-api/signals/dali-signal.h>
#include <dali/devel-api/adaptor-framework/pixel-buffer.h>
+#include <dali/devel-api/adaptor-framework/animated-image-loading.h>
+
+// INTERNAL HEADER
#include <dali-toolkit/public-api/image-loader/async-image-loader.h>
namespace Dali
};
/**
+ * @brief Starts an animated image loading task.
+ * @REMARK_INTERNET
+ * @REMARK_STORAGE
+ * @param[in] asyncImageLoader The ayncImageLoader
+ * @param[in] animatedImageLoading The AnimatedImageLoading to load animated image
+ * @param[in] frameIndex The frame index of a frame to be loaded frame
+ * @return The loading task id
+ */
+DALI_TOOLKIT_API uint32_t LoadAnimatedImage( AsyncImageLoader asyncImageLoader,
+ Dali::AnimatedImageLoading animatedImageLoading,
+ uint32_t frameIndex );
+
+/**
* @brief Starts an image loading task.
* @REMARK_INTERNET
* @REMARK_STORAGE
* @param[in] fittingMode The method used to fit the shape of the image before loading to the shape defined by the size parameter
* @param[in] samplingMode The filtering method used when sampling pixels from the input image while fitting it to desired size
* @param[in] orientationCorrection Reorient the image to respect any orientation metadata in its header
- * @param[in] preMultiplyOnLoad ON if the image color should be multiplied by it's alpha. Set to OFF if there is no alpha
+ * @param[in] preMultiplyOnLoad ON if the image color should be multiplied by it's alpha. Set to OFF if there is no alpha or if the image need to be applied alpha mask.
* @return The loading task id
*/
DALI_TOOLKIT_API uint32_t Load( AsyncImageLoader asyncImageLoader,
* @param[in] maskPixelBuffer Pointer to raw masking data
* @param[in] contentScale The factor to scale the content
* @param[in] cropToMask Whether to crop the content to the mask size
+ * @param[in] preMultiplyOnLoad ON if the image color should be multiplied by it's alpha. Set to OFF if there is no alpha.
* @return The masking task id
*/
DALI_TOOLKIT_API uint32_t ApplyMask( AsyncImageLoader asyncImageLoader,
Devel::PixelBuffer pixelBuffer,
Devel::PixelBuffer maskPixelBuffer,
float contentScale,
- bool cropToMask );
+ bool cropToMask,
+ DevelAsyncImageLoader::PreMultiplyOnLoad preMultiplyOnLoad );
/**
* Connect to this signal if you want to load a PixelBuffer instead of a PixelData.