Re: [info-performer] pfGeoSetCB: copy and setDrawCB problem

New Message Reply Date view Thread view Subject view Author view

From: Alexandre Meyer (a.meyer++at++cs.ucl.ac.uk)
Date: 07/30/2002 07:25:34


Hi Yair,

Yes with the call to setCBIndex it works!! Thanks!!

I though it was something like that, I had tried with a call to init()
but it was an other function! ;-)

Thanks you very much,
Alex

--On Monday, July 29, 2002 06:42:03 PM -0700 Yair Kurzion <yair++at++polygon.engr.sgi.com> wrote:

>
> Hi Alex,
>
> Try calling gsetCB->setCBIndex() right after gsetCB->setDrawCB().
>
> I think you found a bug (Thanks). The call to pfGeoSet::copy overrides some
> internal pfGeoSet flags, and it fails to behave like a pfGeoSetCB.
> The call to setCBIndex resets these flags.
>
> Please let me know whether the fix works for you. If it does, I'll incorporate
> it in the next pf release.
>
> Thanks,
> -yair
>
>
>> I would like to use my own draw callback function for pfGeode geometry of a subpart
>> of my scene graph (to use NVidia Cg compiler).
>>
>> For that I traverse the scene graph and I try to replace all pfGeoSet by pfGeoSetCB
>> like that:
>>
>> pfGeoSet *oldgset = geode->getGSet(i);
>> pfGeoSetCB *gsetCB = new pfGeoSetCB();
>> gsetCB->copy(oldgset);
>> gsetCB->setDrawCB( drawCB, NULL);
>> geode->replaceGSet( oldgset, gsetCB);
>>
>> but it doesn't work, my DrawCB is not used, ?
>> If I comment the line with the copy it works, my callback is used.
>> There is something that I don't understand in the copy function but what?
>>
>> I could write a new copy function that copy a pfGeoSet to a pfGeoSetCB but
>> I would like to understand what is the problem with the standard copy
>> function here, if someone knows ...
>>
>> Thanks,
>> Alex
>>
>>
>> -----------------------------------------------------------------------
>> SIGGRAPH 2002 Friends of Performer Meeting July 24 6:00pm-8:00pm
>> Salon I, Marriott Rivercenter Hotel, San Antonio, TX USA
>> -----------------------------------------------------------------------
>> List Archives, Info, FAQ: http://www.sgi.com/software/performer/
>> Open Development Project: http://oss.sgi.com/projects/performer/
>> Submissions: info-performer++at++sgi.com
>> Admin. requests: info-performer-request++at++sgi.com
>> -----------------------------------------------------------------------
>>
>
>
> --
> \_________ \_____ \__ \__ \_____
> \_________ \_____ \__ \__ \_____ Yair Kurzion
> \__ \__ \____\__ \__ yair++at++sgi.com
> \__ \__ \__ (650) 933-6502
> \__ \__ \__
> \__ \__ \__
>


New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2b29 : Tue Jul 30 2002 - 07:34:12 PDT

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