Re: IV loader bugs/problems

New Message Reply Date view Thread view Subject view Author view

Michael Philip (mphilip++at++technet.sg)
Wed, 31 May 1995 10:08:52 +0800 (SST)


> Problem:
>
> 1. Blinker ==> pfSequence does not work properly.
> I have looked at the code, and it seems as though it should
> work, but it just doesn't seem to be adding children to the
> sequence node.

I'm pretty sure I already reported this problem (any my fix) to
the Performer team.

It looks to me like the Inventor traversal doesn't descend all the
SoBlinker children. My workaround was to make a PerfBlink wrapper
class that does the same thing as the PerfLOD class does for
SoLevelOfDetail nodes - I guess for the same reason.

Here's some code:

////////////////////////////////////////////////////////////////////////

#include <Inventor/nodes/SoSubNode.h>
#include <Inventor/nodes/SoBlinker.h>

class PerfBlink : public SoBlinker {
    SO_NODE_HEADER(PerfBlink);
public:
    static void initClass();
    PerfBlink();
protected:
    virtual void callback(SoCallbackAction *action);
private:
    virtual ~PerfBlink();
};

SO_NODE_SOURCE( PerfBlink );

void
PerfBlink::initClass()
{
    classTypeId = SoType::overrideType(SoBlinker::getClassTypeId(),
        createInstance);
    parentFieldData = SoBlinker::getFieldDataPtr();
}

PerfBlink::PerfBlink()
{
    SO_NODE_CONSTRUCTOR( PerfBlink );
}

PerfBlink::~PerfBlink()
{
}

void
PerfBlink::callback( SoCallbackAction *action )
{
    SoGroup::doAction( action );
}

void InitConverter()
{
    PerfBlink::initClass();
}

////////////////////////////////////////////////////////////////////////

Michael Philip, Symbolic Research Pte Ltd, Singapore
Fax:(65)295-5311 AppleLink:FEA0001 mphilip++at++technet.sg


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:51:33 PDT

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