Hello Robert, My gut tells me that the time to make a call to a virtual function versus inlined code is far less than the actual code being executed. That said, a little gedanken experiment to get an idea of how many blinking lights we may have to deal with is in order:
Let us say, for the sake of argument, for a flight simulation in a non urban area it would be a couple per aircraft. Given that most simulations tend to not have a lot of aircraft then we aren't talking about a lot. Let's say 10 (why not :) ). In an urban environment we are talking about hazard lights to indicate large towers and buildings of significant height (relative to the surrounding buildings). Let's say 100 buildings (including towers), each with a few lights, so 300. Generally not all of those lights will be in the field of view, and it wouldn't be prudent to render them all of the time at distance (LOD controlled). So, let's say our worse case is 310 lights. My analysis may be a bit self serving but I don't feel that it will be a noticeable issue in the general case. -B -----Original Message----- From: osg-users-boun...@lists.openscenegraph.org [mailto:osg-users-boun...@lists.openscenegraph.org] On Behalf Of Robert Osfield Sent: Friday, June 22, 2012 2:19 AM To: osg-users@lists.openscenegraph.org Subject: Re: [osg-users] LightPointNode BlinkSequence class modification questions. HI Brad, On 21 June 2012 23:23, Brad Colbert <bcolb...@rscusa.com> wrote: > How would you feel about changing the osg::Vec4 BlinkSequence::color(double > time,double length) const to virtual? > > I would like to customize the behaviour of this call but I'm currently unable > to because it is inlined and not virtual. The method is original inline for performance reasons so the question I'd pose is simply what performance impact would we see with changing to virtual. This would depend on just how many light points in the scene might have a BlinkSequence attached. How many are you using or would you expect to be used on screen at any one time? Robert. _______________________________________________ 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