Skip to main content

Question about pre-rendered objects and Blender 2.61.0

Please note these java.net forums are being decommissioned and use the new and improved forums at https://community.oracle.com/community/java.
5 replies [Last post]
zachary1234
Offline
Joined: 2010-12-11

Obviously, the Java3D api includes the option to include a pre-rendered object file into an
in-progress 3D world program.
What is the idea file format for this pre rendered obejct? Is it *.obj?

I use Blender to export my 3D objects. What is the appropriate file format to export to
from 2.61.0 of that program, in Windows 7 (*.obj or otherwise)?
If otherwise, where may I find a free utility to convert from a Blender file
to the precise file format Java3D would like?

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
interactivemesh
Offline
Joined: 2006-06-07

In my opinion the X3D scene graph is semantically very close the Java 3D scene graph. In case of object files you benefit from Java 3D build-in loader. Collada (.dae) is popular since Google's SketchUp provides a dae-exporter.

You also have to consider which external file format is capable of representing the complexity of your Blender models and which of its exporters generate adequate exports.

Alternative loaders:

*.blend : java3d and blender http://www.java.net/forum/topic/javadesktop/java-desktop-technologies/java-3d/java3d-and-blender
*.dae : Sweet Home 3D's Collada Loader 'com.eteks.sweethome3d.j3d.DAELoader', Sweet Home 3D source http://www.sweethome3d.com/download.jsp
*.x3d : XModelImporter http://www.java.net/node/706300

August

harveyh
Offline
Joined: 2005-01-01

I'd second the sweethome3d loader, it's been working well for me, particularly with output from sketchup.

Harvey

zachary1234
Offline
Joined: 2010-12-11

What file formats does the Java 3D built in loader support?

Does this include *.obj files saved direct from Blender 2.61.0 ?

interactivemesh
Offline
Joined: 2006-06-07

Java 3D's build-in *.obj/object loader : 'com.sun.j3d.loaders.objectfile.ObjectFile' http://download.java.net/media/java3d/javadoc/1.5.2/index.html

Blender 2.6.1 : File -> Export -> Wavefront (.obj)
Java 3D conform 'Export OBJ' settings (enable) :
- Include Normals (or let the loader calculate them)
- Include UVs (for textures)
- Write Materials
- Triangulate Faces
- Objects as OBJ Groups ( disable: Objects as OBJ Objects)
(- Material Groups ?)

August

zachary1234
Offline
Joined: 2010-12-11

Thank you for answering my question in the affirmative!