1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
|
From: Debian FlightGear Crew <team+flightgear@tracker.debian.org>
Date: Tue, 16 Jun 2020 14:29:04 +0200
Subject: The class "osg::Camera" has no member named "resize" in OSG 3.2
simgear/scene/viewer/Compositor.cxx | 3 +++
1 file changed, 3 insertions(+)
diff --git a/simgear/scene/viewer/Compositor.cxx b/simgear/scene/viewer/Compositor.cxx
index ffaccdb..da304db 100644
@@ -22,6 +22,7 @@
#include <osgViewer/Renderer>
#include <osgViewer/Viewer>
+#include <osg/Version>
#include <simgear/math/SGRect.hxx>
#include <simgear/props/props_io.hxx>
@@ -236,8 +237,10 @@ Compositor::resized()
continue;
// Resize both the viewport and its texture attachments
+#if OSG_MIN_VERSION_REQUIRED(3,4,0)
camera->resize(pass->viewport_width_scale * _viewport->width(),
pass->viewport_height_scale * _viewport->height());
+#endif
}
}
|