Hi Alex, What OS, Hardware, drivers are you using?
Robert. On Thu, Jun 18, 2009 at 8:24 PM, Pecoraro, Alexander N<[email protected]> wrote: > Is there a different or better way to test for anti-aliasing support than to > just call osg::DisplaySettings::instance()->setNumMultiSamples() repeatedly > with smaller and smaller values, which doesn’t seem to work for me anyway > (so hopefully the answer is yes). I tried to have it set the number of multi > samples and then call realize() on the viewer and if it failed to realize I > have it try a smaller value for number of samples. What ends up happening is > that it starts at 8, fails, then tries 4, which I know is supported by my > video card so it should work and it appears to work, but the window opens > and it is just black and nothing seems to render to it. So I’m wondering if > my way of checking for anti-aliasing support is wrong. Here is the debug > output from my attempts to make this work: > > > > Setting anti-aliasing samples to: 8 > > GraphicsContext::registerGraphicsContext 0x8e4ff20 > > Relaxing traits > > Error: Not able to create requested visual. > > close(1)0x8e4ff20 > > close(0)0x8e4ff20 > > GraphicsContext::unregisterGraphicsContext 0x8e4ff20 > > Viewer::realize() - No valid contexts found, setting up view across all > screens. > > GraphicsContext::getWindowingSystemInterface() 0x8e4c030 0x102ee20 > > GraphicsContext::registerGraphicsContext 0x8e51e28 > > Relaxing traits > > Error: Not able to create requested visual. > > close(1)0x8e51e28 > > close(0)0x8e51e28 > > GraphicsContext::unregisterGraphicsContext 0x8e51e28 > > GraphicsWindow has not been created successfully. > > Viewer::realize() - failed to set up any windows > > > > Trying anti aliasing samples at 4 > > Viewer::realize() - No valid contexts found, setting up view across all > screens. > > GraphicsContext::getWindowingSystemInterface() 0x8e4c030 0x102ee20 > > GraphicsContext::registerGraphicsContext 0x8e51e28 > > GraphicsContext::getWindowingSystemInterface() 0x8e4c030 0x102ee20 > > GraphicsContext::createNewContextID() creating contextID=0 > > Updating the MaxNumberOfGraphicsContexts to 1 > > GraphicsWindow has been created successfully. > > X window successfully opened > > > > So even though it appears that the “GraphicsWindow has been created > successfully”, my app is not able to render anything into the window. The > funny thing is that if I start with a number of multi-samples value of 4 > then everything works fine. Its only if I first test the realize() with a > multi-samples value that is not supported by my card that makes subsequent > valid multi-samples values not work. > > > > Any advice for how to fix this? > > > > Thanks. > > > > Alex > > _______________________________________________ > 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

