|
From: James W. <ja...@fr...> - 2007-02-24 03:11:39
|
Roger Holmes wrote: > More optimisation. Especially I would like to reduce going all > around the houses for a group to submit the groups within it. > One recursive routine in the stack trace is unavoidable, but at > the moment we have three routines repeatedly calling each > other. One knows what the submission mode is e.g Picking > but the other ones keep checking the mode, which must be > slowing us down. There has got to be a better way. I'm not sure which 3 routines you're talking about here. When you submit a group for rendering, the call stack looks something like Q3Object_Submit E3Object_Submit E3View_SubmitRetained e3view_submit_retained_render e3group_display_submit_contents e3group_submit_contents Q3Object_Submit I say "something like" because if you subclass the view object, as Geom Test does, you have the subclass submit-retained-render method in there. It's true that two of these, e3group_display_submit_contents and e3group_submit_contents, check the view mode, but E3View_GetViewMode is just an accessor and should be quite fast. One way I see to shorten the cycle is to have e3group_submit_contents call E3View_SubmitRetained directly instead of calling Q3Object_Submit. That looks safe, so I'll go ahead and commit it. Also, is anyone using kQ3CallbackElementTypeBeforeRender and kQ3CallbackElementTypeAfterRender, which are checked every time through e3view_submit_retained_render? I put those in a few years back, but I don't use them any more, as I decided that I can do more with less trouble by subclassing the view object. -- James W. Walker, Innoventive Software LLC <http://www.frameforge3d.com/> |