Multi-level context caching
[platform/core/uifw/dali-adaptor.git] / dali / internal / graphics / gles-impl / gles-graphics-texture.h
index dc7d921..19619e4 100644 (file)
 
 // INTERNAL INCLUDES
 #include "gles-graphics-resource.h"
+#include "gles-graphics-types.h"
 
 namespace Dali::Graphics::GLES
 {
 using TextureResource = Resource<Graphics::Texture, Graphics::TextureCreateInfo>;
+class Sampler;
 
 /**
  * The Texture class represents a GPU texture object. It's slightly
@@ -65,6 +67,15 @@ public:
   }
 
   /**
+   * @brief Returns the type of the bound Gl texture
+   * @return The type of the bound Gl texture
+   */
+  [[nodiscard]] BoundTextureType GetTextureTypeId() const
+  {
+    return mCreateInfo.nativeImagePtr ? BoundTextureType::TEXTURE_EXTERNAL_OES : static_cast<BoundTextureType>(mCreateInfo.textureType);
+  }
+
+  /**
    * @brief Called when initializing the resource
    *
    * @return True on success