diff Framework/Viewport/ViewportBase.h @ 905:88bf49aebc13

introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
author Alain Mazy <alain@mazy.be>
date Wed, 17 Jul 2019 16:56:53 +0200
parents 0aff28f15ea2
children 685c9a2d115f
line wrap: on
line diff
--- a/Framework/Viewport/ViewportBase.h	Wed Jul 17 15:33:34 2019 +0200
+++ b/Framework/Viewport/ViewportBase.h	Wed Jul 17 16:56:53 2019 +0200
@@ -49,5 +49,21 @@
     }
 
     virtual ScenePoint2D GetPixelCenterCoordinates(int x, int y) const;
+
+    virtual void Refresh()
+    {
+      GetCompositor().Refresh();
+    }
+
+    virtual unsigned int GetCanvasWidth() const
+    {
+      return GetCompositor().GetCanvasWidth();
+    }
+
+    virtual unsigned int GetCanvasHeight() const
+    {
+      return GetCompositor().GetCanvasHeight();
+    }
+
   };
 }