Hi Robert, It didn't work, but adding another cast did....
unsigned int num_files_per_row = std::max(osg::round(sqrt(static_cast<float>(std::min(max_videos, static_cast<unsigned int>(files.size()))))),(static_cast<float> (1.0))); Seems to make it compile... I will shove it through to submissions... Cheers Martin From: [email protected] [mailto:[email protected]] On Behalf Of Robert Osfield Sent: 05 November 2012 09:37 To: OpenSceneGraph Users Subject: Re: [osg-users] compiler error (osgmultiplemovies) HI Sebastian and Martin, I have added a static cast, could you do an svn update and let me know if this fixes the build. Thanks, Robert. On 3 November 2012 12:13, Sebastian Messerschmidt <[email protected]> wrote: Hello Martin, unsigned int num_files_per_row = std::max(osg::round(sqrt(std::min(max_videos, static_cast<unsigned int>(files.size())))), 1.0); is the line I have. Try to static cast the result of osg::round to unsigned int. Same goes for the sqrt, which expects float or double. The VC2010 is a bit more picky than the older versions. Hello, I am receiving an error when compiling latest SVN in osgmultiplemovies which is as follows: Error 1 error C2668: 'sqrt' : ambiguous call to overloaded function D:\Coding\OSG\OpenSceneGraph\examples\osgmultiplemovies\osgmultiplemovies.cp p 654 1 example_osgmultiplemovies Error 2 error C2780: 'const _Ty &std::max(const _Ty &,const _Ty &,_Pr)' : expects 3 arguments - 2 provided D:\Coding\OSG\OpenSceneGraph\examples\osgmultiplemovies\osgmultiplemovies.cp p 654 1 example_osgmultiplemovies No idea why, this is with VS2010. Regards Martin _______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org _______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
_______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

