From: Donald Tidrow (dtidrow++at++patriot.net)
Date: 05/05/2005 20:49:31
Have you tried reversing the order of pfFrame()/pfSync()? IIRC,
pfSync() usually was called first, so maybe there's some order
dependency in the internal mutexes or whatever they use internally.
Don
On Thu, 2005-05-05 at 17:35, Jonathan Kelly wrote:
> I wrote a very small test program to debug why a second call to pfFrame
> would crash the program. All I'm doing is opening up a window and attaching
> a camera to it. I call pfFrame and pfSync after I open the window to display
> the window then while in the sim loop I make a call to pfFrame and pfSync.
> The catch comes when I make the call to pfFrame in the sim loop. Here is the
> small test app that I wrote, where could I be going wrong???
>
> Jonathan
>
> #include <Performer/pf.h>
> #include <Performer/pf/pfPipe.h>
> #include <Performer/pf/pfScene.h>
> #include <Performer/pf/pfPipeWindow.h>
> #include <Performer/pf/pfChannel.h>
>
> int main(int argc, char *argv[])
> {
> pfPipe *pipe;
> pfPipeWindow *pw;
> pfScene *scene;
>
> /* Initialize Performer */
> pfInit();
>
> pfMultiprocess(PFMP_APPCULLDRAW);
>
> /* Configure */
> pfConfig();
>
>
> scene = new pfScene();
>
> /* Configure and open GL window */
>
> pipe = pfGetPipe(0);
>
> pw = new pfPipeWindow(pipe);
>
> pw->setName("OpenGL Performer");
>
> // set the size and origin of the pipe window
> pw->setOriginSize(0, 0, 800, 600);
> pw->open(); // open the new window
>
> pfFrame();
> pfSync();
>
> pfPipe *pCameraPipe = pfGetPipe(0);
> pfChannel *pChannel = new pfChannel(pCameraPipe); // create a camera from
> the first pipe
>
> // sim loop
> for(;;)
> {
> pfFrame();
> pfSync();
> }
>
> pfExit();
> exit(0);
> }
>
This archive was generated by hypermail 2b29 : Thu May 05 2005 - 20:49:42 PDT