Forums Login/signup

3d objects in java

+Pie Number of slices to send: Send
I'm trying to write a program to mimic a 3d architectural representation of a room in java (entities are: windows, walls, ceiling, floor; no furniture or anything inside). Then I will take some input parameters and optimize the spacing of the windows on the building.

I originally made the drawing in google sketchup, exported it as xml, parsed the xml into java classes, so now I java classes (wall, window, etc) containing coordinates for all the vertices of each entity. What I did before was hackish, but adding more functionality might be messy so I want to use existing libraries such as Point and Rectangle that have methods like setLocation, distance.

Are there any java libraries that support 3d geometries? The java.awt.Rectangle and java.awt.Point classes only support 2d shapes. The library should support methods like setLocation, move, etc because I will have to rearrange the windows on each wall after the optimization.

Let me know if my explanation is unclear.
+Pie Number of slices to send: Send
"calmze", please check your private messages for an important administrative matter.
+Pie Number of slices to send: Send
You'll need to look at libraries like:

JWJGL
JOGL
Java3D
+Pie Number of slices to send: Send
More specifically, I would like 3d rectangle and 3d point classes that support all the operations of java.awt.Rectangle and java.awt.Point (which is only 2d). I don't necessarily have to draw anything, just perform the optimization and get updated objects. Eventually I will write the optimization back to xml and make a new drawing in google sketchup.
+Pie Number of slices to send: Send
The first of Gregg's list I would look at is Java3D. It supports 3D primitives. It's also somewhat higher-level than JOGL.

You'll find both on dev.java.net.
+Pie Number of slices to send: Send
JOGL is a wrapper around OpenGL, a quite low-level 3D graphics library. It is only interesting if you want to work with 3D graphics.

LWJGL (I guess that's what Gregg meant instead of JWJGL) is a game programming library.

Java3D will probably be more useful to you.
[ June 26, 2008: Message edited by: Jesper Young ]

reply
reply
This thread has been viewed 1505 times.
Similar Threads
JOGL or LWJGL
Need Clarification on Different Java Package/Technology?
compile error
Best 3D option in an applet?
how to Monitor Registry
More...

All times above are in ranch (not your local) time.
The current ranch time is
Jun 28, 2025 17:38:26.