Re: Traverse Question

New Message Reply Date view Thread view Subject view Author view

Lance R. Marrou (marrou++at++vsl.ist.ucf.edu)
Fri, 2 Dec 1994 14:08:26 -0500 (EST)


On Fri, 2 Dec 1994, Aaron Hightower wrote:
...
> Another way you could do stuff per frame is to install node callbacks.
> Check out the man page on pfNodeTravFuncs for information on this. The
> short story is that this allows you to call one of your functions from
> the cull, draw or intersection process if you need to do so. It will
> pass the data for the node to your function when and if the
> cull/draw/isect process encounters the given node that has a callback
> installed. You'll still want to use the above function to actually
> find the nodes in the scene graph so that you can install the callbacks
> on them.
...

Your code looked good, though the new pfuTraverser, as mentioned below by
Kowsik Guruswamy does the same thing, and allows for ready-to-use simple
options (see the man page).

I just wanted to point out that using the draw and/or cull callbacks for
some node processing could seriously hurt the performance. Unless you
really need to be in the draw process or the cull process you probably
should refrain from doing application processing there. Furthermore, you
cannot access the full scene graph in the draw process (if you need it).
Of course, in MP_APPCULLDRAW, it doesn't matter.

Kowsik Guruswamy wrote:
>Take a look at pfuTraverser, which I think would solve your problem.
>
>You can set up preFunc and postFunc in the pfuTraverser structure and
>calculate whatever you want. You could do this after you load the scene
>and before you enter the main loop.

_______________________________________________________
IST __ E-mail: marrou++at++vsl.ist.ucf.edu
Visual / / ______ /\____ ______ ______
Systems / / / _ / / __ // ____// ____/
Lab / /__ / /_/ / / / / // /___ / __/_ R. Marrou
________/____//____/\\/_/ /_//_____//_____/____________


New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2.0b2 on Mon Aug 10 1998 - 17:50:43 PDT

This message has been cleansed for anti-spam protection. Replace '++at++' in any mail addresses with the '@' symbol.