Merge "Add InputMethodSettings property to TextEditor." into devel/master
[platform/core/uifw/dali-toolkit.git] / dali-scene-loader / public-api / environment-definition.cpp
index 16c8e2c..c95883f 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2020 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2021 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.
@@ -23,24 +23,22 @@ namespace Dali
 {
 namespace SceneLoader
 {
-
 EnvironmentDefinition::RawData
-  EnvironmentDefinition::LoadRaw(const std::string& environmentsPath) const
+EnvironmentDefinition::LoadRaw(const std::string& environmentsPath) const
 {
   RawData raw;
-  auto loadFn = [&environmentsPath](const std::string& path, CubeData& cd) {
-    if (path.empty())
+  auto    loadFn = [&environmentsPath](const std::string& path, CubeData& cd) {
+    if(path.empty())
     {
       cd.data.resize(6);
-      for (auto& face : cd.data)
+      for(auto& face : cd.data)
       {
-        face.push_back(PixelData::New(new uint8_t[3]{ 0xff, 0xff, 0xff }, 3, 1, 1, Pixel::RGB888, PixelData::DELETE_ARRAY));
+        face.push_back(PixelData::New(new uint8_t[3]{0xff, 0xff, 0xff}, 3, 1, 1, Pixel::RGB888, PixelData::DELETE_ARRAY));
       }
     }
     else if(!LoadCubeMapData(environmentsPath + path, cd))
     {
-      ExceptionFlinger(ASSERT_LOCATION) << "Failed to load cubemap texture from '" <<
-        path << "'.";
+      ExceptionFlinger(ASSERT_LOCATION) << "Failed to load cubemap texture from '" << path << "'.";
     }
   };
 
@@ -54,18 +52,18 @@ EnvironmentDefinition::Textures EnvironmentDefinition::Load(RawData&& raw) const
   Textures textures;
 
   // This texture should have 6 faces and only one mipmap
-  if (!raw.mDiffuse.data.empty())
+  if(!raw.mDiffuse.data.empty())
   {
     textures.mDiffuse = raw.mDiffuse.CreateTexture();
   }
 
   // This texture should have 6 faces and 6 mipmaps
-  if (!raw.mSpecular.data.empty())
+  if(!raw.mSpecular.data.empty())
   {
     textures.mSpecular = raw.mSpecular.CreateTexture();
   }
   return textures;
 }
 
-}
-}
+} // namespace SceneLoader
+} // namespace Dali