Hi
i think this can be fixed with just sending resize even manually after viewer have been realized and event handlers set up:
osgGA::GUIEventAdapter * event = viewer.getEventQueue()->createEvent();
event->setEventType(osgGA::GUIEventAdapter::RESIZE);
viewer.getEventQueue()->addEvent(event);
event->setEventType(osgGA::GUIEventAdapter::RESIZE);
viewer.getEventQueue()->addEvent(event);
or
int x, y, width, height;
osgViewer::ViewerBase::Windows windows;
viewer.getWindows(windows);
windows.front()->getWindowRectangle(x,y,width,height);
viewer.getEventQueue()->windowResize(x,y,width,height);
I believe both pieces should work same way
Cheers.
20.02.2013, 15:31, "Christian Buchner" <christian.buch...@gmail.com>:
producing an invalid scaling matrix. So the screen stays blank (no model is rendered at all) when using square Texture2D objects.I am currently finding a problem with the osgoit demo (as found in OSG 3.0.1). The osgviewer by default starts in full screen mode, and never generates an initial RESIZE event. I am testing this on Windows, if that matters.
The _texWidth and _texHeight members of the DepthPeeling object remain at their default values of 0. While this seems to generate reasonably sized shadowing maps (why?), this has the unfortunate side effect that the CullCallback never receives an update with the correct texture width and height. When not using texture rectangles and when USE_NON_POWER_OF_TWO_TEXTURE #define is not set, it will execute this line:
m.postMultScale(osg::Vec3d(viewport->width()/double(_texWidth), viewport->height()/double(_texHeight), 1));
Feeding an appropriate default value to the DepthPeeling constructor with the screen resolution fixes it.Christian,2013/2/17 Mathias Fröhlich <mathias.froehl...@gmx.net>
Hi List,osgoit concentrates on the order independent transparency and does this with a
On Sunday, February 17, 2013 08:20:55 Sajjadul Islam wrote:
> are both the same is theory ? What are the differences between them
> implementation-wise ?
minimal requirement on the state of the displayed model. Also it uses a
minimal set of OpenGL features/extensions to make this run on as much
hardware/drivers as possible.
Greetings
Mathias
_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
_______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org