Re: subclassing pfGroup

New Message Reply Date view Thread view Subject view Author view

Randy Stiles (stiles++at++aic.lockheed.com)
Wed, 27 Mar 1996 22:36:58 -0800


Hi Swami,

Sorry, I re-read your message, and indeed you are familiar
with the subclassing examples in pfiv. A good question
for Jim Helman is if needsApp() is also needed always
(returning true or false?) because all 3 subclassing examples in
the libpfiv source define it (probably because they
are 'live').

public:
    virtual int app(pfTraverser *trav);
    virtual int needsApp() { return TRUE; }

-Randy

Randy Stiles wrote:
>
> Hi,
>
> There are examples of subclassing Performer nodes in
> the source code for libpfiv, the Inventor loader. Jim
> Helman subclassed pfDCS for Inventor-like rotors, etc.
>
> <stiles++at++gabriel> pwd
> /usr/share/Performer/src/lib/libpfdb/libpfiv
> <stiles++at++gabriel> ls
> Makefile Pendulum.h Rotor.h Shuttle.h pfiv.C
> Pendulum.C Rotor.C Shuttle.C pfSoClasses.h pfivdefs.h
>
> You will probably have to look in the Inventor loader
> code anyways, since I found you have to modify it to
> deal with SoWWWAnchor properly if your are using Inventor 2.1
> to load VRML files (recommended). If your system admin
> is like most, he/she did not install the libpfdb source
> code from the Performer 2.0 CD since it is not installed
> by default. So you will want to use swmgr or inst to install
> it from the Performer 2.0 CD.
>
> performer_dev.src.loader 03/03/96 Performer2.0 Loader Code
>
> -Randy
>
> Swaminathan wrote:
> >
> > Hi, I implementing a vrml viewer using Performer and the inventor loader.
> > I'm subclassing pfGroup into pfWWWinline and pfWWWAnchor nodes to help
> > me have full vrml functionality. Unfortunately, I dont have much
> > information on subclassing nodes, other than the instances in the pfiv
> > source code. A specific question is whether to include other functions
> > besides pfWWWInline::app(pfTraverser *) as detailed in the inventor
> > loader. Pointers to source code examples of subclassing and comments in
> > general are greatly appreciated.
> >
> > bye
> > Swami
> >
> > P.S. I've added name, and bounding box fields to extend the pfGroup node
> > to be a pfWWWInline node. When I load in the inlines, I attach the
> > subgraphs to the pfWWWinline node using AddChild().

-- 
// Randy Stiles  stiles++at++aic.lockheed.com      Orgn 9620 Bldg 255
// Lockheed Martin Advanced Technology Center 3251 Hanover Street 
// office: 415.354.5256  fax: 415.354.5235    Palo Alto, CA 94304-1192
// http://vet.parl.com/~vet/people/stiles/

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:52:35 PDT

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