Hi Laurens, Good detective work. Definitely a wired combinational problem. Could you post the file that you modified with a note which version it's based upon. A git commit/PR would do just as well.
Cheers, Robert. On 20 December 2016 at 16:38, Voerman, L. <[email protected]> wrote: > Hi all, > this is a very old oddity - stats look a bit weird on a empty scene. > the actual problem is the osg default for the blend function is never set if > the main camera renders absolutely nothing, so the opengl default blendfunc > ( GL_ONE, GL_ZERO) is still active. > To fix this I added to > src\osgViewer\StatsHandler.cpp > in the function setUpScene: > stateset->setGlobalDefaults(); // add default blend function > before the line > stateset->setMode(GL_LIGHTING,osg::StateAttribute::OFF); > > Regards, Laurens. > > On Thu, Dec 15, 2016 at 8:47 PM, Riccardo Corsi <[email protected]> > wrote: >> >> Hi Robert, >> >> please find attached the hacked viewer which starts also without any >> loaded model. >> >> Here are the details of my setup (even though I've noticed this issue >> since several osg versions now) >> - Win10 / VisualStudio 2013 >> - nVidia GTX970 with recent drivers >> - osg 3.5.3 >> >> Thank you, >> Riccardo >> >> >> >> On Thu, Dec 15, 2016 at 8:16 PM, Robert Osfield <[email protected]> >> wrote: >>> >>> Hi Riccardo, >>> >>> Could you post your modified osgviewer so we can attempt to reduce >>> things. >>> >>> Also please provide details on the OS platform, OSG version, drivers, >>> hardware as these are all likely to affect the result. >>> >>> Robert. >>> >>> On 15 December 2016 at 18:44, Riccardo Corsi <[email protected]> >>> wrote: >>> > Hi all, >>> > >>> > I've found out that when I show the stats handler without having set >>> > any >>> > data on the viewer, >>> > its rendering is corrupted (fonts, transparency) - see attached >>> > screenshot, >>> > I simply forced osgViewer to run without any loaded model. >>> > >>> > The Stats are rendered without being attached to the scene or as a >>> > slave, >>> > the stats camera instead is directly added to the first available >>> > graphics >>> > context, >>> > so I'm afraid some initialization is missing. >>> > >>> > I have the same problem with another GUI tool I'm rendering with the >>> > same >>> > technique. >>> > Can anybody provide an hint? >>> > Thank you, >>> > Riccardo >>> > >>> > >>> > _______________________________________________ >>> > 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 >> > > > _______________________________________________ > 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

