Moved the type alias of the RefCountedTexture to the vulkan-types header file
authorAngelos Gkountis <a.gkountis@samsung.com>
Fri, 18 May 2018 09:29:01 +0000 (10:29 +0100)
committeradam.b <jsr184@gmail.com>
Fri, 25 May 2018 15:51:13 +0000 (16:51 +0100)
Change-Id: I50c5686ef56ff42b9bdf7b44ae920aac4d3ddde9

dali/graphics/vulkan/api/vulkan-api-controller.cpp
dali/graphics/vulkan/api/vulkan-api-texture.cpp
dali/graphics/vulkan/api/vulkan-api-texture.h
dali/graphics/vulkan/vulkan-graphics-texture.cpp
dali/graphics/vulkan/vulkan-graphics-texture.h
dali/graphics/vulkan/vulkan-standalone-test.cpp
dali/graphics/vulkan/vulkan-types.h

index 746b5ac..2bcae9e 100644 (file)
@@ -208,7 +208,7 @@ struct Controller::Impl
   }
 
   // resources
-  std::vector<Vulkan::TextureRef> mTextures;
+  std::vector<Vulkan::RefCountedTexture> mTextures;
   std::vector<Vulkan::RefCountedShader>  mShaders;
   std::vector<Vulkan::RefCountedBuffer>  mBuffers;
 
index 8c0fb5d..ba29750 100644 (file)
@@ -95,7 +95,7 @@ struct Texture::Impl
     return true;
   }
 
-  Vulkan::TextureRef mTexture;
+  Vulkan::RefCountedTexture mTexture;
   VulkanAPI::TextureFactory& mTextureFactory;
   Vulkan::Graphics& mGraphics;
 };
@@ -107,7 +107,7 @@ Texture::Texture( Dali::Graphics::API::TextureFactory& factory )
 
 Texture::~Texture() = default;
 
-Vulkan::TextureRef Texture::GetTextureRef() const
+Vulkan::RefCountedTexture Texture::GetTextureRef() const
 {
   return mImpl->mTexture;
 }
index 4f10748..40b161f 100644 (file)
@@ -43,7 +43,7 @@ public:
 
   bool Initialise();
 
-  Vulkan::TextureRef GetTextureRef() const;
+  Vulkan::RefCountedTexture GetTextureRef() const;
 
 private:
   struct Impl;
index 503298f..e7bca71 100644 (file)
@@ -223,9 +223,9 @@ struct Texture::Impl
  *
  */
 
-TextureRef Texture::New( Graphics& graphics, uint32_t width, uint32_t height, vk::Format format )
+RefCountedTexture Texture::New( Graphics& graphics, uint32_t width, uint32_t height, vk::Format format )
 {
-  auto result = TextureRef( new Texture( graphics, width, height, format ));
+  auto result = RefCountedTexture( new Texture( graphics, width, height, format ));
   if( !result->mImpl->Initialise() )
   {
     result.Reset();
index 9ac5ee1..6b1631f 100644 (file)
@@ -96,7 +96,6 @@ private:
   std::unique_ptr<Impl> mImpl;
 };
 
-using TextureRef = Handle<Texture>;
 }
 } // namespace Graphics
 } // namespace Dali
index 39c4bf3..f2f9dc8 100644 (file)
@@ -399,8 +399,8 @@ void test_handle()
 }
 
 RefCountedPipeline create_pipeline(Dali::Graphics::Vulkan::Graphics &graphics,
-                            Dali::Graphics::Vulkan::RefCountedShader vertexShader,
-                            Dali::Graphics::Vulkan::RefCountedShader fragmentShader)
+                                   Dali::Graphics::Vulkan::RefCountedShader vertexShader,
+                                   Dali::Graphics::Vulkan::RefCountedShader fragmentShader)
 {
   using namespace Dali::Graphics::Vulkan;
   auto pipelineInfo = vk::GraphicsPipelineCreateInfo{};
index 71f2341..1b59f5c 100644 (file)
@@ -320,6 +320,7 @@ using RefCountedDescriptorSet = Handle<class DescriptorSet>;
 using RefCountedSwapchain = Handle<class Swapchain>;
 using RefCountedSurface = Handle<class Surface>;
 using RefCountedSampler = Handle<class Sampler>;
+using RefCountedTexture = Handle<class Texture>;
 /*
 #pragma GCC diagnostic push
 #pragma GCC diagnostic ignored "-Wframe-larger-than="