C++ node->setTravData

New Message Reply Date view Thread view Subject view Author view

Angus Henderson (angus++at++death.reading.sgi.com)
Tue, 26 Mar 1996 16:25:24 +0000


Has anyone got an example of a Performer 2.0-C++-node->setTravData ?

I had a working version with Performer 1.2-C-pfNodeTravData, but when I cannot
get a valid pointer to my draw process in 2.0.

I do something like....

ExpTravData *edt[MAX_EXPLOSIONS];

    for(i = 0; i < MAX_EXPLOSIONS; i++)
    {
        edt[i] =
(ExpTravData*)pfMalloc(sizeof(ExpTravData),pfGetSharedArena());

        node->setTravData( PFTRAV_DRAW, edt[i] );
    }

In the pre node draw callback I always get a pointer to the last element of edt
and none of the others.

I am using a C type call to pfMalloc 'cos that's what perfly.C does, I could
also use an example of how to use pfMemory->malloc on user data instead.

ANGus


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:52:35 PDT

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