wood burning stoves 2.0*
The moose likes Other JSE/JEE APIs and the fly likes Problem in adding view to Cube in java 3d Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Other JSE/JEE APIs
Bookmark "Problem in adding view to Cube in java 3d" Watch "Problem in adding view to Cube in java 3d" New topic
Author

Problem in adding view to Cube in java 3d

Neeba Rebbaca
Ranch Hand

Joined: Oct 21, 2008
Posts: 151
I tired to add multiple cubes of size 25. I have translated the view.But still i can able to see only one cube not the others. I went wrong somewhere.But don't know where. Please help me...


>
Neeba Rebbaca
Ranch Hand

Joined: Oct 21, 2008
Posts: 151
please help me with some idea...I'm badly in need of that...
Neeba Rebbaca
Ranch Hand

Joined: Oct 21, 2008
Posts: 151
I want to draw a cubes of size 25 and in many number at different co-ordinates.These are the steps i followed.

1. Declared and initialised Virtual Universe.
2. Declared and set x,y,z for HiResCoord.
3. Declaring and passing hirescoord and virtualuniverse obj to Locale.
4. Declaring and BranchGroup(scenegraph) and adding an array of ColorCube to the branchgroup.
5. Declaring another BranchGroup(View graph).
6. Declaring an array of TransformGroup and Transform3D.
7. Inside the loop, translating to new position. The x,y values are incremented by loop.(-250,250,-1000 and -215,215,-1000). and transform3d object is added to transformgroup object. And transform3d object is inverted.
8. Declared and initialised ViewPlatform and added view graph.
9. Declared , initialised view class and add PhysicalEnvironment and PhysicalBody to it.
10. set backClipDistance for 200 and and frontClipDistance for 2.
11. And added canvas3d .
12. And added canvas3d to applet.

I tried to add two cubes at different coordinates.But they are getting overlapped.I couldn't able to trace out.Please help me solving the issue.

 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Problem in adding view to Cube in java 3d
 
Similar Threads
Help Java3d
facing problem while creating a Road/Pathway using Java3D
Scaling the Image.
Java 3d program problwm
Error (compile time) for JAVAX package