Hi Alex,
           I tried what you have suggested. It works to some extent ie. the texture was loaded but only a part of it. For eg suppose there is a jpg with three vertical strips with colors red/white/blue,  and if I texture map this jgp on a sphere with radius as per cmds given by you, then sphere looks blue at all point on the sphere surface. So what must be happening?
                                                                         =
                                                                         =
       Ajax.

----- Original Message -----
From: Alex Hew
Sent: Monday, September 09, 2002 6:23 PM
Subject: Re: [JAVA3D] texture mapping

Hi Ajax,
 
TextureLoader load = new TextureLoader("c:/model/grass.jpg", null);
Texture text = load.getTexture();
 
 Appearance app = new Appearance();
 app.setTexture(text);
 Shape3D shape = new Shape3D(geometry, app);
 
I did it this way. Hope it helps.
 
-Alex-
----- Original Message -----
From: ajaxinc
Sent: Monday, September 09, 2002 8:32 PM
Subject: [JAVA3D] texture mapping

what is the simplest way to texture map a jpg over a shape3D

Reply via email to