Re: [osg-users] Dynamic Modification..

2009-05-04 Thread Ignazio
I resolve my problem in this way: while(!(viewer.done)) { //code that modify structure viewer.(frame); } Thanks a lot. Ignazio -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=11271#11271

Re: [osg-users] Dynamic Modification..

2009-04-22 Thread Ignazio
OK Paul..thanks a lot -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=10592#10592 ___ osg-users mailing list osg-users@lists.openscenegraph.org

Re: [osg-users] Dynamic Modification..

2009-04-21 Thread Allen Saucier
kool robert, thx for the correction. I just pulled that code from an example I found. It works but I never understood the details - I'm a newbie too. So all the help I can get, I'll take it! :) Thx again. Allen -- Read this topic online here:

Re: [osg-users] Dynamic Modification..

2009-04-21 Thread Ignazio
Thanks a lot Allen and Robert. I'll try to modify my source code with our directions.. I explane you my true problem.I must change the solid color dinamically, during the execution. -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=10529#10529

Re: [osg-users] Dynamic Modification..

2009-04-21 Thread Allen Saucier
welcome. And I believe the only way to change anything in osg dynamically is to do so with function calls that make those changes within the viewer frame loop like so: while(!viewer.done()) { // YOUR CODE GOES HERE TO CHANGE A // NODE IN THE OSG SCENE TREE // BEFORE osg Updates the

Re: [osg-users] Dynamic Modification..

2009-04-21 Thread Jean-Sébastien Guay
Hi Allen, welcome. And I believe the only way to change anything in osg dynamically is to do so with function calls that make those changes within the viewer frame loop like so: As Robert said earlier today, that's one way, the other is to create an update callback that you will attach to

Re: [osg-users] Dynamic Modification..

2009-04-21 Thread Ignazio
Thanks Allen..Now I try to do what you suggested me. -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=10533#10533 ___ osg-users mailing list osg-users@lists.openscenegraph.org

Re: [osg-users] Dynamic Modification..

2009-04-21 Thread Ignazio
Thanks, I change the methods like you..So a last question..I change color for example for 3 seconds,after this time I must set the default solid color.. And during this time others sphere must brighten..Thanks a lot.. -- Read this topic online here:

Re: [osg-users] Dynamic Modification..

2009-04-21 Thread Jean-Sébastien Guay
Hello Ignazio, So a last question..I change color for example for 3 seconds,after this time I must set the default solid color.. And during this time others sphere must brighten..Thanks a lot.. It's up to you to define your application's behavior any way you like... We can't really go

Re: [osg-users] Dynamic Modification..

2009-04-21 Thread Ignazio
Thanks a lot.I try to do what you suggested..Thanks -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=10548#10548 ___ osg-users mailing list osg-users@lists.openscenegraph.org

Re: [osg-users] Dynamic Modification..

2009-04-21 Thread Paul Martz
@lists.openscenegraph.org Subject: Re: [osg-users] Dynamic Modification.. Thanks..Accoding you I must extend the UpdatCallBack,in this way class lux : public osg::Drawable::UpdateCallback { virtual void operator()( osg::ShapeDrawable* drawable) { drawable -setColor(osg

Re: [osg-users] Dynamic Modification..

2009-04-21 Thread Paul Martz
-users-boun...@lists.openscenegraph.org [mailto:osg-users-boun...@lists.openscenegraph.org] On Behalf Of Paul Martz Sent: Tuesday, April 21, 2009 1:16 PM To: osg-users@lists.openscenegraph.org Subject: Re: [osg-users] Dynamic Modification.. Please take a look at the osgcallback example, it will be much

[osg-users] Dynamic Modification..

2009-04-20 Thread Ignazio
Hi, I'm a new member of this forum..So if I make mistakes please apologize me.. I have a problem... :) I create a 3d application(a simple application, I have a set of cones and Cylinders). The structure of application is : osg::ref_ptrosg::Group root; Cosg::Cone* unitCone; osg::Cylinder*

Re: [osg-users] Dynamic Modification..

2009-04-20 Thread Paul Martz
@lists.openscenegraph.org Subject: [osg-users] Dynamic Modification.. Hi, I'm a new member of this forum..So if I make mistakes please apologize me.. I have a problem... :) I create a 3d application(a simple application, I have a set of cones and Cylinders). The structure of application is : osg::ref_ptrosg::Group root

Re: [osg-users] Dynamic Modification..

2009-04-20 Thread Allen Saucier
Hey, here's the article Paul is speaking about#058; http://forum.openscenegraph.org/viewtopic.php?t=2190 I'm one of the guys in that discussion. I asked how to modify a line dynamically. Since you're using viewer.run(), that makes life difficult. I believe you'll need to use the viewer frame

Re: [osg-users] Dynamic Modification..

2009-04-20 Thread Robert Osfield
HI Allen, viewer.frame() calls viewer.updateTraversal(), and viewer.run() calls viewer.frame() so your suggest frame loop would only call updateTraversal() twice. Instead to expand viewer.run() - a frame loop with it's component parts you do (please look at the implementation itself to confirm