Hi,
I had create a simple application in wich I load an sphere from a 3DS file, in the same application y create a triangle of the same size with this code:
 
Shape3D shape = new Shape3D();
  TriangleStripArray geometry = new TriangleStripArray(4,
             TriangleStripArray.COORDINATES,
             new int[] {4});
  Point3d[] points = new Point3d[] {new Point3d(0.3, 0.3, 0),
        new Point3d(-0.3, 0.3, 0),
               new Point3d(-0.3, -0.3, 0),
               new Point3d(0.3, -0.3, 0)};
  geometry.setCoordinates(0, points);
  shape.setGeometry(geometry);  
  Appearance appearance = new Appearance();
  ColoringAttributes ca = new ColoringAttributes();
  ca.setColor(new Color3f(1, 0, 0));
  appearance.setColoringAttributes(ca);  
  Material material = new Material(new Color3f(0.2f, 0.2f, 0.2f),
       new Color3f(0.1f, 0, 0),
       new Color3f(1, 0.8f, 0.8f),
       new Color3f(1.0f, 1.0f, 1.0f), 
       64);
  appearance.setMaterial(material);  
  shape.setAppearance(appearance);
  objRoot.addChild(shape);
 
The sphere has reflection, shadows.... bu the triangle is completly red without shadows, reflexion...(color set in the coloringAtributtes of the appearance) and if delete the lines of the coloring attributes the traingle is completly white. Why the appearance of this triangle is not been displayed? The bounds are well definied.
Thanks,
Boby 
=========================================================================== 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".

Reply via email to