Add api for get original image size 80/198180/4
authorSunghyun kim <scholb.kim@samsung.com>
Tue, 22 Jan 2019 02:01:36 +0000 (11:01 +0900)
committersunghyun kim <scholb.kim@samsung.com>
Thu, 24 Jan 2019 10:05:29 +0000 (10:05 +0000)
Change-Id: I3a137213ffcfc19f0bdaf429023355e9e5479d2d

dali/devel-api/adaptor-framework/image-loading.cpp
dali/devel-api/adaptor-framework/image-loading.h

index af05256..aed3189 100644 (file)
@@ -67,6 +67,10 @@ ImageDimensions GetClosestImageSize( const std::string& filename,
   return dimension;
 }
 
+ImageDimensions GetOriginalImageSize( const std::string& filename )
+{
+   return TizenPlatform::ImageLoader::GetClosestImageSize( filename, ImageDimensions(0, 0), FittingMode::DEFAULT, SamplingMode::BOX_THEN_LINEAR, true );
+}
 
 Devel::PixelBuffer DownloadImageSynchronously( const std::string& url, ImageDimensions size, FittingMode::Type fittingMode, SamplingMode::Type samplingMode, bool orientationCorrection )
 {
index a7995ba..7230a19 100755 (executable)
@@ -72,6 +72,15 @@ DALI_ADAPTOR_API ImageDimensions GetClosestImageSize(
   bool orientationCorrection = true );
 
 /**
+ * @brief Get the size of an original image
+ * @param[in] filename name of the image.
+ *
+ * @return dimensions to original image
+ */
+DALI_ADAPTOR_API ImageDimensions GetOriginalImageSize(
+  const std::string& filename);
+
+/**
  * @brief Load an image synchronously from a remote resource.
  *
  * @param [in] url The URL of the image file to load.