thanks, it works !!!! ;D Date: Tue, 29 Apr 2014 12:34:42 +0200 From: trajce.nikolov.n...@gmail.com To: osg-users@lists.openscenegraph.org Subject: Re: [osg-users] Problems with keyboard events
Hi Alvaro, your update callback is expecting PositionAttitudeTransform, so make circulo() function to return it. Something like sphere->getOrCreateStateSet()->setAttribute(rojo); PositionAttitudeTransform* pat = new PositionAttitudeTransform; pat->addChild(sphere); return pat; I think with this change it will work NIck On Tue, Apr 29, 2014 at 10:38 AM, alvaro ginestar rodriguez <alvarogines...@hotmail.com> wrote: Hi i'm learning OSG and i have some problems with keyboard events. I want move a sphere with the keyboard. I´m following OSG tutorial Handling Keyboard Input to Update a Callback: http://trac.openscenegraph.org/projects/osg/wiki/Support/Tutorials/BasicKeyboardInput And i don´t know why it dosen´t work.The code : https://github.com/a5rojo/CirculoOSG/blob/master/circulo.cpp THX _______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org -- trajce nikolov nick _______________________________________________ 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