]> git.mxchange.org Git - flightgear.git/blobdiff - src/Canvas/canvas_mgr.hxx
Canvas: Image/Window unifying and allow using canvas inside canvas.
[flightgear.git] / src / Canvas / canvas_mgr.hxx
index 10cbe9a764a6bae20fd9463d215c36fe4447c822..568da3d61615b65825034cacdce86f7c534328b6 100644 (file)
@@ -19,6 +19,7 @@
 #ifndef CANVAS_MGR_H_
 #define CANVAS_MGR_H_
 
+#include "canvas_fwd.hpp"
 #include "property_based_mgr.hxx"
 
 class CanvasMgr:
@@ -27,9 +28,20 @@ class CanvasMgr:
   public:
     CanvasMgr();
 
+    /**
+     * Get ::Canvas by index
+     *
+     * @param index Index of texture node in /canvas/by-index/
+     */
+    CanvasPtr getCanvas(size_t index) const;
+
     /**
      * Get OpenGL texture name for given canvas
      *
+     * @deprecated This was only meant to be used by the PUI CanvasWidget
+     *             implementation as PUI can't handle osg::Texture objects.
+     *             Use getCanvas(index)->getTexture() instead.
+     *
      * @param Index of canvas
      * @return OpenGL texture name
      */