From 13531757c45927600097fff84fb473b0e0e1a743 Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Wed, 27 Jan 2010 17:12:40 +0000 Subject: [PATCH] From Serge Lages, "Here is a fix for the Quicktime plugin, with the previous version, the size for some videos was not correct, using GetMovieBoundsRgn instead of GetMovieBox returns the real movie size. " --- src/osgPlugins/quicktime/MovieData.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/osgPlugins/quicktime/MovieData.cpp b/src/osgPlugins/quicktime/MovieData.cpp index 89fb0156b..6ca1d1a53 100644 --- a/src/osgPlugins/quicktime/MovieData.cpp +++ b/src/osgPlugins/quicktime/MovieData.cpp @@ -93,11 +93,10 @@ void MovieData::load(osg::Image* image, std::string afilename, float startTime) } - Rect bounds; + Rect bounds = (*GetMovieBoundsRgn(_movie))->rgnBBox; - GetMovieBox(_movie, &bounds); - _checkMovieError("Can't get movie box\n"); - + _checkMovieError("Can't get movie bounds\n"); + OffsetRect(&bounds, -bounds.left, -bounds.top); SetMovieBox(_movie, &bounds); _checkMovieError("Can't set movie box\n");