Hi folks !
is there a reason why Groups can not be nested inside an OrderedGroup, or a
DecalGroup ?
what I want to to is:
Group checkerBoard = new Group();
checkerBoard .addChild(createPlane(...));
checkerBoard .addChild(createPlane(...));
...
checkerBoard .addChild(createPlane(...));
// checkerBoard is a group of coplanar squares
Text2D decal = ceateTextDecal(...);
// some text decaled on top of the checker board
// to avoid z-buffer fighting, let's use a DecalGroup
Group decalGroup = new DecalGroup();
decGroup.addChild(checkerBoard);
decGroup.addChild(decal);
...
universe.addBranchGraph(scene);
throws the exception:
java.lang.IndexOutOfBoundsException: Index: 2, Size: 2
at java.util.ArrayList.RangeCheck(ArrayList.java:491)
at java.util.ArrayList.get(ArrayList.java:307)
at
javax.media.j3d.OrderedGroupRetained.setAuxData(OrderedGroupRetained.java:32
5)
at
javax.media.j3d.OrderedGroupRetained.setNodeData(OrderedGroupRetained.java:3
63)
at javax.media.j3d.NodeRetained.doSetLive(NodeRetained.java:621)
at javax.media.j3d.GroupRetained.doSetLive(GroupRetained.java:2095)
at javax.media.j3d.GroupRetained.setLive(GroupRetained.java:2069)
at
javax.media.j3d.OrderedGroupRetained.setLive(OrderedGroupRetained.java:332)
at
javax.media.j3d.GroupRetained.childDoSetLive(GroupRetained.java:2077)
at javax.media.j3d.GroupRetained.doSetLive(GroupRetained.java:2126)
at
javax.media.j3d.TransformGroupRetained.setLive(TransformGroupRetained.java:5
43)
at
javax.media.j3d.GroupRetained.childDoSetLive(GroupRetained.java:2077)
at javax.media.j3d.GroupRetained.doSetLive(GroupRetained.java:2126)
at
javax.media.j3d.BranchGroupRetained.setLive(BranchGroupRetained.java:161)
at javax.media.j3d.Locale.doAddBranchGraph(Locale.java:204)
at javax.media.j3d.Locale.addBranchGraph(Locale.java:163)
which is not very helpful, actually ...
the same happens if I use an OrderedGroup instead of a DecalGroup.
It works with a simple Group (except for the z-buffer problems, of course).
Is this a bug ?
-- Peter
===========================================================================
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".