Michael Philip (mphilip++at++technet.sg)
Thu, 8 Aug 1996 03:27:28 -0700
If I understand the question correctly, the problem is that you can
easily use pfCycleBuffers for the attribute lists of dynamic objects,
but if one of the things you would like to animate is the actual number
of primitives (pfGSetNumPrims), there is no function to synchronize
this with the pfCycleBuffer'd lists.
To get around this problem, I use a ring buffer of frame stamped
"update requests" in shared memory. I queue an "update request"
for the pfGSetNumPrims for a pfGeoSet when I change its
pfCycleBuffer data. Then, in the draw-process callback function,
I process the appropriate update requests for the current frame
before pfDraw()'ing it.
The "update request" is just the framestamp (pfGetFrameStamp()
called from APP), a pointer to the pfGeoSet (in shared memory)
and the requested numPrims value.
I also use this method to swap pfGeoSet attribute lists and bind
textures for dynamic objects at a specific frame.
Hope this helps.
Good luck,
Mike Philip
-- Michael Philip Symbolic Research Pte Ltd Singapore Phone:+65-9615-9181 Fax:+65-285-5311 mphilip++at++netcom.com
======================================================================= List Archives, FAQ, FTP: http://www.sgi.com/Technology/Performer/ Submissions: info-performer++at++sgi.com Admin. requests: info-performer-request++at++sgi.com
This archive was generated by hypermail 2.0b2 on Mon Aug 10 1998 - 17:53:19 PDT