Hi Dave,
You should use the following callback to retrieve the cloned copy of
TransformGroup which Behavior refer to:
public void updateNodeReferences(NodeReferenceTable referenceTable) {
super.updateNodeReferences(referenceTable);
newTransformGroup = (TransformGroup)
referenceTable.getNewObjectReference(oldTransformGroup);
....
}
- Kelvin
---------------
Java 3D Team
Sun Microsystems Inc.
>I have a Behavior similar to a RotationInterpolator which given a
>TransformGroup changes the transform. I want to clone a BranchGroup which
>contains the Behavior and the TransformGroup.
>
> BranchGroup
> |
> /\
> / \
> Behavior TransformGroup
>
>The documentation says you must include in your class:
>
> public Node cloneNode(boolean forceDuplicate) {
> UserSubClass usc = new UserSubClass();
> usc.duplicateNode(this, forceDuplicate);
> return usc;
> }
>
>
>If my initial constructor was :
>SimpleRotateBehavior b = new SimpleRotationBehavior(TransformGroup tg);
>
>I assume you replace UserSubClass with SimpleRotateBehavior but how do you
>get the cloned TransformGroup to give to the cloned Behavior.
>
>I think I might be missing something fundamental here, so any help or any
>starting point would be greatly appreciated.
>
>Thanks in advance,
>
>Dave.
>
>===========================================================================
>To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
>of the message "signoff JAVA3D-INTEREST". For general help, send email to
>[EMAIL PROTECTED] and include in the body of the message "help".
===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA3D-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".