Hi !
Featured games (84)
games approved by the League of Dukes
Games in Showcase (604)
Games in Android Showcase (171)
games submitted by our members
Games in WIP (654)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  3D Model  (Read 3050 times)
0 Members and 1 Guest are viewing this topic.
Offline arkdm

Junior Devvie

Go Pooh on yourself

« Posted 2005-06-06 18:59:57 »

Hi -

I'm a newbie when it comes to JOGL, and I was wondering if anyone knows any easy ways to import a 3D model into a JOGL app? Any ideas?

Offline pepijnve

Junior Devvie

Java games rock!

« Reply #1 - Posted 2005-06-07 12:31:19 »

OpenGL (and thus jogl too) is only a rendering API. How you load data and render it is application specific. There are however some model loaders available in the jogl-demos which you might be able to use. I haven't used these yet so I can't comment on how complete they are and what kind of functionality they provide.
Offline kevglass

« JGO Spiffy Duke »

Medals: 272
Projects: 25
Exp: 18 years

Coder, Trainee Pixel Artist, Game Reviewer

« Reply #2 - Posted 2005-06-07 12:46:36 »

If MD2 (Quake 2 models) would do, this thread might help:

Even if not, the code contained might give you some points.


Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline arkdm

Junior Devvie

Go Pooh on yourself

« Reply #3 - Posted 2005-06-07 15:30:49 »

Ok - I'm using blender right now for modeling, it looks like all of the blender md2 exporters have dissapeared off of the internet, but I can export to .obj. I tried using the file from the jogl-demos section, which required the file, which errored on compile. Can someone show/tell me how to load a .obj file?

Thanks for all of your help!
Offline arkdm

Junior Devvie

Go Pooh on yourself

« Reply #4 - Posted 2005-06-07 17:29:39 »

...or would you suggest switching to Xith3d?
Offline Ken Russell

JGO Coder

Java games rock!

« Reply #5 - Posted 2005-06-07 17:46:42 »

If you want to load 3D models of any complexity (for example, articulated or skinned models) I would recommend you use a higher-level API like Xith3D. The model readers in the jogl-demos workspace are not designed to be general-purpose loaders. What was the compilation error you got with demos.util.FloatList? It should work fine; it's distributed in all of the release builds of JOGL.
Offline arkdm

Junior Devvie

Go Pooh on yourself

« Reply #6 - Posted 2005-06-07 18:24:43 »

It doesn't like the "assert" commands. And, is Xith3D faster or slower than JOGL?

Thanks again!
Offline Ken Russell

JGO Coder

Java games rock!

« Reply #7 - Posted 2005-06-07 21:05:34 »

You're probably trying to compile with a JDK earlier than 1.4. JOGL only works with JDK 1.4 and later.

Xith3D is built on top of either JOGL or LWJGL and it isn't reasonable to make performance comparisons between the two APIs. Xith3D does seem to be a pretty good / fast implementation of Java3D-like APIs and given the kinds of operations you're trying to do I'd recommend you look at it.
Offline arkdm

Junior Devvie

Go Pooh on yourself

« Reply #8 - Posted 2005-06-07 21:16:14 »

I'm working off of jdk 1.4.2..., and JRE I've ran some JOGL things before.

Alright, I took your advice and installed Xith3D, but I'm having some trouble running the test program, here's my error:

C:\xith\xith3d\libs>java -cp xith3d.jar;C:\j2sdk1.4.2_07\jre\lib\ext\vecmath.jar
C:\j2sdk1.4.2_07\jre\lib\ext\junit.jar;C:\j2sdk1.4.2_07\jre\lib\ext\vorbis.jar c
starting frame speed test
Exception in thread "main" java.lang.AbstractMethodError: com.xith3d.render.jogl
        at com.xith3d.render.jogl.CanvasPeerImpl.render(
        at com.xith3d.scenegraph.View.renderOnce(
        at com.xith3d.scenegraph.View.renderOnce(
        at com.xith3d.test.CubeTest.<init>(
        at com.xith3d.test.CubeTest.main(

I get an empty white screen when I try to run it, and when I go back to the command prompt I get this. Any ideas?

Thank you so much guys! All of you at this forum are helpful!
Offline Ken Russell

JGO Coder

Java games rock!

« Reply #9 - Posted 2005-06-07 23:40:00 »

I would post this question on the Xith3D forum. It looks like your version of Xith3D is really old and you're running with a newer version of JOGL, but I know  that Xith3D has been recently updated to work with the latest JOGL.
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline BK

Junior Newbie

« Reply #10 - Posted 2005-06-14 18:41:15 »

As i am looking for a jogl model Loader too (especially for 3ds files), i was searching this Forum. I found a couple of topics which seem to match, but  all the links refer to the old Forum. For example:

"A 3ds loader:;action=display;num=1061796369"

Although I searched some code or external links for a 3ds loader I didn't find anything here.
How can I find the topic in the new forum or can someone give me a link to a 3ds loader written for jogl?

Would be nice. Thanks in advance.
Offline wanao

Junior Newbie

« Reply #11 - Posted 2006-01-01 03:46:59 »

Hi, Smiley
i have been searched that for a long time, and finally i find this package "mri-v3ds" Grin
but it only decode the 3ds files, so i write a small render class.
it's simple, you can look though my code to know how to render a 3ds file.

please change file name  "mri-v3ds.txt" to "mri-v3ds.jar", because it don't allow me
to upload a .jar file. and "Model3DS.txt" it's class i write.

P.S.  it can not read textures by itself
Offline thiagosc

Senior Newbie

« Reply #12 - Posted 2006-01-05 20:00:04 »


Right now I'm struggling with the loader question. Isn't anything for just fetching data from a 3ds (or any other format) file for me render as I wish?

The reason for me to hesitant about using Xith is that I'm planning to use OSGi for having a plugin system similar to what we see on Eclipse, with support of versioning and so on, and I'd divide the game into separate independent modules (bundles is the correct word).

A monolithic solution such as Xith defeats the whole purpose of modularizing it. In the end i'd be yet another layer, a frontend to Xith, that would only add overhead and make things more complicated than they need to be.
Pages: [1]
  ignore  |  Print  
You cannot reply to this message, because it is very, very old.

bilznatch (24 views)
2015-08-04 11:03:17

SHC (39 views)
2015-08-01 03:58:20

Jesse (24 views)
2015-07-29 04:35:27

Riven (46 views)
2015-07-27 16:38:00

Riven (25 views)
2015-07-27 15:35:20

Riven (27 views)
2015-07-27 12:26:13

Riven (18 views)
2015-07-27 12:23:39

BurntPizza (41 views)
2015-07-25 00:14:37

BurntPizza (54 views)
2015-07-24 22:06:39

BurntPizza (33 views)
2015-07-24 06:06:53
List of Learning Resources
by gouessej
2015-07-09 11:29:36

How Do I Expand My Game?
by bashfrog
2015-06-14 11:34:43

List of Learning Resources
by PocketCrafter7
2015-05-31 05:37:30

Intersection Methods
by Roquen
2015-05-29 08:19:33

List of Learning Resources
by SilverTiger
2015-05-05 10:20:32

How to: JGO Wiki
by Mac70
2015-02-17 20:56:16

2D Dynamic Lighting
by ThePixelPony
2015-01-01 20:25:42

How do I start Java Game Development?
by gouessej
2014-12-27 19:41:21 is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!