AntiAlias, Highlight, Locate node PROBLEMS !!!

New Message Reply Date view Thread view Subject view Author view

DreamTeam Ltd. (dreamt++at++netvision.net.il)
Wed, 24 Jul 1996 15:58:01 -0700


PERFORMER QUESTIONS
                      ------------------------

 1) I want to use anti-aliasing in my program. I tried:

       a) "pfAntialias(PFAA_ON)" after opening the window.

          It had no effect.

       b) "gstate->setMode(PFSTATE_ANTIALIAS, PFAA_ON)".

          It made the polygons COMPLETELY black

    what should I do to make anti-aliasing work ???

 2) I need to find a node in a performer-tree by a name. I use "lookup"
for
    the job. In one of the cases, where the tree is:

                                 ----------
| grp |
                                 ----------
                                  / \
                             -------- -------
|sphere| |Persp|
                             -------- -------
|
                             --------
|geode |
                             --------

   I write "animation_nodes[i] = grp->lookup(obj_name,
pfNode::getClassType())",
   and I get "NULL" for "obj_name" which is "sphere".

   In a few other cases it works.

    I by-passed the problem by querying specifically for all the
    node-types (i.e lookup(obj_name, pfGeode::getClassType() etc..),
    but isn't there a way to make it work for "pfNode::getClassType()" ??

 3) I have a pfHighLight problem. The source is:

    if (pfIsOfType(node, pfGeode::getClassType())) {
      pfGeode *geode = (pfGeode *) node;

      pfHighlight *highlight = new pfHighlight;
      highlight->setMode(PFHL_LINES);

      highlight->setColor( PFHL_FGCOLOR, 1.0, 1.0, 1.0);

      for (int i = 0; i < geode->getNumGSets(); i++) {
        geode->getGSet(i)->setHlight(highlight);
         
geode->getGSet(i)->getGState()->setMode(PFSTATE_ENHIGHLIGHTING,PFTR_ON); }
    }

    It works FINE on an ONYX R10000, running IRIX 6.2 and Performer 2.1,
and
    on Indy's running 5.3 and Performer 2.0, it crashes for certain
nodes.
    All these geode-nodes are childs of pfMorph.

    BUT - if I change the mode to "highlight->setMode(PFHL_NORMALS)"
                               or "highlight->setMode(PFHL_BBOX_LINES)"

          then it works !!

    Is there a known bug of Performer or Irix that prevents highlighting
    in few of the modes ??

    if not - what might be wrong with my code ??

 If someone knows one of the answers. please let me know.

 Thanks in advance.

Rami Mayer
Programmer
DreamTeam Ltd.
Tel:+972-9-559855
Fax:+972-9-559615
email:dreamt++at++netvision.net.il
=======================================================================
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:53:13 PDT

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