Hi!

> This might accomplish what you want:
> 
> 
>   Appearance app = new Appearance();
>   Material mat = new Material( );
>   mat.setDiffuseColor( 1.0f, 1.0f, 1.0f );
> 
>     // Set up the transparency properties
>     TransparencyAttributes ta = new TransparencyAttributes();
>     ta.setTransparencyMode(ta.BLENDED);
>     ta.setTransparency(0.0f);
> 
>   app.setTransparencyAttributes(ta);
>   app.setMaterial( mat );
>   Texture2D surfTex = loadTexture("texture.gif", this);
>   app.setTexture(surfTex);
> 
> 
> The material should have white for diffuse color, otherwise the texture's
> color will be mixed with the material color.  Then you make the appearance
> transparent, so all that shows is the texture.  The result is, wherever you
> texture is transparent, your object is transparent

But I don�t want a transparent object! Perhaps I didn�t explain well.
I have a gif with transparent background. In java3d I create a box and I
want to put this gif as the texture of the box! When I do this the
background of the gif becomes white instead of transparent!

Thanks!

-------------------------------------------------
./--\.          Ana Isabel Pina Moreira Boto
.    .          Mail: [EMAIL PROTECTED]
 \--/                 [EMAIL PROTECTED]
                ICQ: 24914295
-------------------------------------------------

�����������������������
To subscribe/unsubscribe, send mail to [EMAIL PROTECTED]
Java 3D Home Page: http://java.sun.com/products/java-media/3D/

Reply via email to