Cache NPatch textures
[platform/core/uifw/dali-toolkit.git] / dali-toolkit / internal / visuals / visual-factory-cache.h
index cb1b890..0b77e53 100644 (file)
@@ -17,9 +17,6 @@
  * limitations under the License.
  */
 
-// INTERNAL INCLUDES
-#include "svg/svg-rasterize-thread.h"
-
 // EXTERNAL INCLUDES
 #include <dali/public-api/math/uint-16-pair.h>
 #include <dali/public-api/object/ref-object.h>
@@ -29,6 +26,9 @@
 #include <dali/devel-api/common/owner-container.h>
 #include <dali/devel-api/object/weak-handle.h>
 
+// INTERNAL INCLUDES
+#include <dali-toolkit/internal/visuals/npatch-loader.h>
+#include <dali-toolkit/internal/visuals/svg/svg-rasterize-thread.h>
 
 namespace Dali
 {
@@ -42,6 +42,8 @@ namespace Internal
 class ImageAtlasManager;
 typedef IntrusivePtr<ImageAtlasManager> ImageAtlasManagerPtr;
 
+class NPatchLoader;
+
 /**
  * Caches shaders and geometries. Owned by VisualFactory.
  */
@@ -182,13 +184,19 @@ public:
 
   /**
    * Get the image atlas manager.
-   * @return A pointer pointing to the atlas manager
+   * @return A pointer to the atlas manager
    */
   ImageAtlasManagerPtr GetAtlasManager();
 
   /**
+   * Get the N-Patch texture cache.
+   * @return A reference to the N patch loader
+   */
+  NPatchLoader& GetNPatchLoader();
+
+  /**
    * Get the SVG rasterization thread.
-   * @return A pointer pointing to the SVG rasterization thread.
+   * @return A raw pointer pointing to the SVG rasterization thread.
    */
   SvgRasterizeThread* GetSVGRasterizationThread();
 
@@ -248,6 +256,8 @@ private:
   Renderer mWireframeRenderer;
 
   ImageAtlasManagerPtr mAtlasManager;
+  NPatchLoader mNPatchLoader;
+
   SvgRasterizeThread*  mSvgRasterizeThread;
 };