Add image to the 3D canvas in Java3d

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Add image to the 3D canvas in Java3d

gandalf
I am working on a project where I have to show a visualization of various shapes on the canvas. Is there any way I can directly add .png/.jpg images on the canvas? I wish to see images in the scene.
Reply | Threaded
Open this post in threaded view
|

Re: Add image to the 3D canvas in Java3d

gouessej
Administrator
This post was updated on .
Hi

Thank you for clarifying your original question. In this case, you have to create a polygon (a quad would be enough), set its texture and vertex coordinates, and use a texture. Look at Texture, TextureAttributes and GeometryArray.setTextureCoordinates().

Edit.: this example seems to be simple enough to show you how to do that:
http://www.vrupl.evl.uic.edu/oldsite/VRLabAcc/about_vrlab/java3d/lesson05/index.html
Julien Gouesse | Personal blog | Website
Reply | Threaded
Open this post in threaded view
|

Re: Add image to the 3D canvas in Java3d

gandalf
Hi, the link seems to be broken. Do you have any other example/tutorial like this one. Thanks
Reply | Threaded
Open this post in threaded view
|

Re: Add image to the 3D canvas in Java3d

gouessej
Administrator