Re: Question about Draw callback

New Message Reply Date view Thread view Subject view Author view

Mario Veraart (rioj7++at++fel.tno.nl)
Tue, 5 Jan 1999 14:19:22 +0100 (MET)


On Dec 18, Jean-Luc Dery wrote:
>
> On Dec 17, 1:29pm, Angus Dorbie wrote:
> > Subject: Re: Question about Draw callback
> > Eddy Kuo wrote:
> > > 2)
> > > When I have a channel draw callback, and a node traversal draw callback,
> > > What is the order of these callbacks being called. (in a multiprocessors
> > > environment)
> >
> > The channel draw callback calls pfDraw. In pfDraw, when the node is
> > reached
> > in the display list your node draw callbacks will be called before and
> > after
> > it is drawn.
>
> Careful with pfChannel PFCULL_SORT mode; the node draw callbacks might not get
> called as you expect. If draw callbacks are set at pfNode levels, they might
> affect geometry node children from other groups since those are sorted
> according to graphics state optimisation.
>
> Jean-Luc

This is not true. A draw callback always backets the contents of
it's subgraph. It should be in the programmers manual in the section
about traversals but also in the next part from the pfNode manpage.

     setTravMode is used to set additional mode information to control
     traversals. Currently the which argument must be PFTRAV_CONT and the
     mode argument must be PFN_CULL_SORT; the possible choices for the value
     argument are:

          PFN_CULL_SORT_UNCONTAINED
               This is the default value. It means that pre- and post-CULL
               traversal funcs on a node do not prevent the contents of the
               node from being interleaved with the contents of other nodes
               during CULL sorting. This means that (surprise!) the contents
               of the node are not necessarily bracketed by the graphics calls
               made in the pre- and post-CULL node trav funcs. This behavior
               is for the benefit of CULL funcs whose purpose is to return a
               cull result but that don't make any graphics calls. (Note that
               in contrast, pre- and post-DRAW funcs on a node are guaranteed
               to bracket the contents of the node, and therefore they prevent
               the interleaving of the contents of the node with the contents
               of other nodes.)

Mario


New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2.0b2 on Tue Jan 05 1999 - 08:17:50 PST

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