Hi Robert,

robertosfield wrote:
> 
> What do you need it for?
> 

I'm now working to switch my applocation from a continuous frame to an 
ON_DEMAND frame to reduce CPU consumption. Unfotunately even with vsync enabled 
my application takes one cpu core even if nothing changes in the scene. So, for 
the time being I implemented a "dirty falg" in my scene manager so that the 
viewer can check it and call frame() as needed. Then, looking at that 
_boundingSphereComputed flag I was thinking if it may be useful instead of 
implementing my own dirty flag. I found some "setters" (i.e. in 
PositionAttitudeTransform) calls dirtyBounds()  which is propagated to parents.
For sure in my specific case (i.e. one viewer and one scene) a "dirty flag" 
like that would be enough but may be in a more general case (i.e. scene shared 
to more than one Viewer) there must be something stored in each viewer also. I 
thought of a time stamp for example: time of modification to be compared to the 
time stamp of the frame() computed from each viewer. But I don't know if that 
would make sense.

Regards,
Gianni

------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=64630#64630





_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to