Bob Gray wrote:
>
> I define polyhdera as Shape3D and I set its capabilities to include
> ALLOW_GEOMETRY_WRITE and ALLOW_APPEARANCE_WRITE
>
> theShapes[i].setGeometry(thePolyhedra[i].Line());
> theShapes[i].setCapability(Shape3D.ALLOW_GEOMETRY_WRITE);
> theShapes[i].setAppearance(AA.createAppearanceLine(thePolyhedra[i]));
> theShapes[i].setCapability(Shape3D.ALLOW_APPEARANCE_WRITE);
>
> This initially displays the polyhdera as lines.
I have two thoughts on this, but by now means are these answers.
1. Set the capabilities before setting the geometry|appearance. I don't
know if J3D is doing anything funky internally such as immediately
compiling geometry etc inside the setter methods. Considering that all
of the examples you see coming out of Sun always create the object, set
the capabilities, then add the kid nodes, if might be surreptiously
saying something.
2. If you want to swap between outline mode and full geometry, why not
just use the PolygonAttributes of the Appearance to set it to draw lines
or filled polygons? This saves you having to keep two sets of geometry
and appearance. Of course, ignore this comment if your line based
geometry is just the bounding box, not the actual facets.
--
Justin Couch Author, Java Hacker
Snr Software Engineer [EMAIL PROTECTED]
ADI Ltd, Systems Group http://www.vlc.com.au/~justin/
Java3D FAQ: http://tintoy.ncsa.uiuc.edu/~srp/java3d/faq.html
-------------------------------------------------------------------
"Look through the lens, and the light breaks down into many lights.
Turn it or move it, and a new set of arrangements appears... is it
a single light or many lights, lights that one must know how to
distinguish, recognise and appreciate? Is it one light with many
frames or one frame for many lights?" -Subcomandante Marcos
-------------------------------------------------------------------
===========================================================================
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".