Don't know whether this question has been already answered. But just
in case it hasn't been yet...
U know, u never set the appearance 'app' on your sphere 'sp'. Then
some other object tetra... Anyway, sp.setAppearance(app) on your
sphere. Everything should work then. If not, u can also try to set
GENERATE_NORMALS primitive flag. If even this wouldn't work (though it
should 4 sure), create the sphere with another constructer
(Sphere(radius, appearance)).
vladimir
PS: make sure that the material is not too black.
-=V=-
>-------<=============>-------<
Join in Java community now!
http://JavaCafe.VirtualAve.net/
>-------<=============>-------<
In your previous letter u wrote:
--------------------------------
HP> Hi
HP> I need of helps!
HP> How do I put texture in Cube and Sphere objects ?
HP> This code dont works:
HP> Sphere sp = new Sphere();
HP> sp.setCapability(Primitive.GENERATE_TEXTURE_COORDS);
HP> Appearance app = tetra.getAppearance();
HP> TextureLoader tex = new TextureLoader("tijolo.jpg", this);
HP> app.setTexture(tex.getTexture());
HP> TextureAttributes texAttr = new TextureAttributes();
HP> texAttr.setTextureMode(TextureAttributes.MODULATE);
HP> app.setTextureAttributes(texAttr);
HP> app.setMaterial(new Material(black, white, brack, white, 1.0f));
HP> objTrans3.addChild(tetra);
HP> And for ColorCube? How I do put texture?
HP> Send-me examples and/or helps.
HP> Wait yours e-mails.
HP> []s
HP> Haroldo
HP> ______________________________________________________
HP> Get Your Private, Free Email at http://www.hotmail.com
HP> ===========================================================================
HP> To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
HP> of the message "signoff JAVA3D-INTEREST". For general help, send email to
HP> [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".