Did you call realize() on your viewer? ie... myViewer->realize();
On Fri, Jul 6, 2012 at 7:40 AM, Łukasz Lucek <[email protected]> wrote: > Hi, > > I think that I have found a bug in revision 13092. > I'm using osg as part of qt application, so i create an > osgViewer::GraphicsWindowEmbedded like this: > > > Code: > > _gw = new osgViewer::GraphicsWindowEmbedded(x,y,width,height); > > > > > then later, i forward qt events to osg. Especially i forward the resize event > and mouse move events like this: > > > Code: > > void QGraphicsEventAdapter::resizeEvent( QResizeEvent* event ){ > _gw->getEventQueue()->windowResize(0, 0, event->size().width(), > event->size().height()); > _gw->resized(0, 0, event->size().width(), event->size().height()); > } > > void QGraphicsEventAdapter::mouseMoveEvent( QGraphicsSceneMouseEvent* event ){ > QGraphicsScene::mouseMoveEvent(event); > if( event->isAccepted() ) return; > QPoint widgetPos(0,0); > widgetPos = parentView->mapToGlobal(widgetPos); > _gw->getEventQueue()->mouseMotion(event->screenPos().x()-widgetPos.x(), > event->screenPos().y()-widgetPos.y()); > } > > > > > And now, i have an osg camera maniupulator derived from > osgGA::StandardManipulator, with a method > > > Code: > > virtual bool performMovementLeftMouseButton( const double eventTimeDelta, > const double dx, const double dy ); > > > > > my manipulator expects, that the dx and dy values are normalized. It used to > work this way before revision 13092, but after this revision the values are > not normalized anymore. > > I think it has something to do with the change made to the Viewer.cpp file, > however it is to complicated for me to dig into osg event handling. > > ... > > Thank you! > > Cheers, > Łukasz > > ------------------ > Read this topic online here: > http://forum.openscenegraph.org/viewtopic.php?p=48733#48733 > > > > > > _______________________________________________ > 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

