Dear friends,
I tried to remove all children by pressing a button,
so this is the
codes changed from
demo/AWT_interaction/AWTInteractionBehavior.java :
[/CODES]
private BranchGroup BG;
...
public void processStimulus(Enumeration criteria)
{
angle += Math.toRadians(10.0);
trans.rotY(angle);
transformGroup.setTransform(trans);
wakeupOn(criterion);
BG.removeAllChildren();
}
...
[/CODES]
It can be compiled, but when I run it, there is one
error:
Exception occurred during Behavior execution:
javax.media.j3d.RestrictedAccessException: Group: only
a BranchGroup
node may be
removed.
removeAllChildren() is a method can be used by all
subclasses of
Group, so I really wonder why here it can not work.
Would you please
let me know why?
Thanks in advance.
tony
__________________________________________________
Do you Yahoo!?
Yahoo! Web Hosting - establish your business online
http://webhosting.yahoo.com
===========================================================================
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".