From: Thomas Geymayer Date: Fri, 7 Feb 2014 23:26:22 +0000 (+0100) Subject: Canvas: also apply matrix of element to getTransformedBounds. X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=3b23892ccf9c33d05fa642e025c5bdba739bba3b;p=flightgear.git Canvas: also apply matrix of element to getTransformedBounds. Part of the fix for #1333. --- diff --git a/src/Scripting/NasalCanvas.cxx b/src/Scripting/NasalCanvas.cxx index 53f112d66..f476deb40 100644 --- a/src/Scripting/NasalCanvas.cxx +++ b/src/Scripting/NasalCanvas.cxx @@ -158,7 +158,7 @@ naRef f_getDesktop(naContext c, naRef me, int argc, naRef* args) naRef f_elementGetTransformedBounds(sc::Element& el, const nasal::CallContext& ctx) { - osg::BoundingBox bb = el.getTransformedBounds( osg::Matrix::identity() ); + osg::BoundingBox bb = el.getTransformedBounds(el.getMatrix()); std::vector bb_vec(4); bb_vec[0] = bb._min.x();