How to activate the other object?

New Message Reply Date view Thread view Subject view Author view

LIM MING WAH (eng30228++at++leonis.nus.sg)
Wed, 11 Dec 1996 18:37:23 +0800 (SST)


Hello all,
        I have modified perfly such that it creates a different DCS for
every object listed at the command line. But there seems to be an extra
branch with nothing at the end.

                        scene
                        / | |\
                       / | | \
                    dcs dcs dcs dcs
                     / | | \
                   gp gp gp gp
                        / \ \
                       / \ \
                      obj obj light

why is there an extra dcs with nothing at the end? How come I can only
manipulate the last object loaded? can I switch between the object I want
to move? How can I do that?
I have included the part of perfly that I have modified.

    /* Create a DCS for TRACKBALL pfiXformer */
    ViewState->sceneDCS = pfNewDCS();
    ViewState->sceneGroup = pfNewGroup();
    pfAddChild(ViewState->sceneDCS, ViewState->sceneGroup);
    if (ViewState->xformerModel == PFITDF_TRACKBALL)
    {
        pfAddChild(scene, ViewState->sceneDCS);
    }
    else
        pfAddChild(scene, ViewState->sceneGroup);

    /* Load each of the files named on the command line */
    for (i = 0; i < NumFiles; i++)
    {
        for (j = 0; j < ViewState->iterate; j++)
        {

            /* Create a DCS for TRACKBALL pfiXformer */
            ViewState->sceneDCS = pfNewDCS();
            ViewState->sceneGroup = pfNewGroup();
            pfAddChild(ViewState->sceneDCS, ViewState->sceneGroup);
            if (ViewState->xformerModel == PFITDF_TRACKBALL)
            {
                pfAddChild(scene, ViewState->sceneDCS);
            }
            else
                pfAddChild(scene, ViewState->sceneGroup);

            /* Load the database. create a hierarchy under node "root" */
            root = pfdLoadFile(DatabaseFiles[i]);

            if (root == NULL)
            {
                pfNotify(PFNFY_NOTICE, PFNFY_PRINT,
                         "WARNING: could not load \"%s\"",
DatabaseFiles[i]);
                continue;
            }

Thanks a lot!!!!

Jonathan

=======================================================================
List Archives, FAQ, FTP: http://www.sgi.com/Technology/Performer/
            Submissions: info-performer++at++sgi.com
        Admin. requests: info-performer-request++at++sgi.com


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:54:08 PDT

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