Java-Gaming.org    
Featured games (79)
games approved by the League of Dukes
Games in Showcase (475)
Games in Android Showcase (106)
games submitted by our members
Games in WIP (530)
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  
  Empty BranchGroup/Shapes  (Read 2596 times)
0 Members and 1 Guest are viewing this topic.
Online kevglass

JGO Kernel


Medals: 117
Projects: 23
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Posted 2003-11-02 14:20:39 »

Sorry to spam the group, its been a busy day..

I was having a performance problem earlier whenever I loaded an OBJ model into my scene. It turns out it was caused by either an empty BranchGroup or empty Shape3D (i.e. geometry with no vertices) being added to the scene. Having fixed this problem I'm back to the performance I'm used to from Xith. (new version of the loader posted in a mo).

I just thought other people might find this problem also.

Kev

Offline Preston

Senior Member


Medals: 4



« Reply #1 - Posted 2003-11-02 14:52:30 »

Quote
Having fixed this problem I'm back to the performance I'm used to from Xith.

How is this performance? I don't know Xith (or Java3d), but OpenGL on a basic level. If I read your previous postings right, you know both APIs? If so, say you would do some medium complex 3d action with Xith3d: would it be compareable to a "pure Jogl" implementation?

Quote
I just thought other people might find this problem also.

Yes thanks, I'll remember your posting. :-)
Online kevglass

JGO Kernel


Medals: 117
Projects: 23
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #2 - Posted 2003-11-02 15:17:21 »

Writing a pure OpenGL engine is always going to yield better performance (assuming you're an expert on what you're doing). However, writing an engine for a non trivial game is difficult to get right (or good).

If you're just playing around (hobby project) its really a decision you don't have to worry about. Just use what seems most interesting.

From a commerical point of view, it would be far more cost effective to use an engine like Xith3D rather than go for pure opengl. You'll just end up duplicating effort and not finding your bugs as quick (since not as many people will be using the code). Performance wise Xith (and other engines) are fine unless you're trying to push the boundaries of technology.

You larger concern should probably be download footprint (que Cas), since most of the engines, including Xith, get quite large.

I've attempted a bunch of stuff with OpenGL and Java3D. Generally the performance of pure OpenGL looks really good up front but comes down quickly as the scene gets more complex. The tail off with the engines is slow but performance starts at a lower level.

Long post over,

Kev

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

Senior Member


Medals: 4



« Reply #3 - Posted 2003-11-02 16:27:08 »

Quote

Long post over

Thanks for the nice explanation. It's not been too long. :-)

The same afternoon I've asked a similar question in the existing thread named " Java3D, JOGL or Xith3D?" (
http://www.java-gaming.org/cgi-bin/JGNetForums/YaBB.cgi?board=xith3d;action=display;num=1067530262;start=0#8)  Hopefully I'm not doubling the topic now and yes I'm somewhat offtopic now, sorry Kev.
Offline winkman

Senior Newbie




Java games !


« Reply #4 - Posted 2003-11-02 21:19:32 »

Hello

the obj loaders give me problems on linux

If i change the line:
BufferedReader reader = new BufferedReader(new InputStreamReader(OBJLoader.class.getClassLoader().getResourceAsStream(objFile)));

to:
BufferedReader reader = new BufferedReader(new InputStreamReader(this.getClass().getClassLoader().getResourceAsStream(objFile)));

it works as expected (when also done for materialLoader)
used as is it never finds the resource (altough clustered all around the classpath) but gives back null

i am using j2sdk1.4.2_b28 on suse9.0
and the loader from 3days ago.

has anyone tested this on linux sucessfully ??

regards
Martin
Offline Yuri Vl. Gushchin

Senior Member




Speak Java!


« Reply #5 - Posted 2003-11-03 16:47:56 »

I was testing emtpy groups some time ago and had no performance diffs.

Can you please make a short test so I can look deeper in the problem?

Thanks for testing,
Yuri

Yuri Vl. Gushchin
JProof Group
Online kevglass

JGO Kernel


Medals: 117
Projects: 23
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #6 - Posted 2003-11-03 17:34:41 »

I can try, if you'd already tested empty group then its more likely it was empty geometry in shapes. e.g. not having any vertices in the geometry inside the shape3d.

Kev

Online kevglass

JGO Kernel


Medals: 117
Projects: 23
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #7 - Posted 2003-11-04 10:32:32 »

Quote

Hello

the obj loaders give me problems on linux

If i change the line:
BufferedReader reader = new BufferedReader(new InputStreamReader(OBJLoader.class.getClassLoader().getResourceAsStream(o bjFile)));

to:
BufferedReader reader = new BufferedReader(new InputStreamReader(this.getClass().getClassLoader().getResourceAsStream(o bjFile)));

it works as expected (when also done for materialLoader)
used as is it never finds the resource (altough clustered all around the classpath) but gives back null

i am using j2sdk1.4.2_b28 on suse9.0
and the loader from 3days ago.

has anyone tested this on linux sucessfully ??

regards
Martin


Sorry, I missed this earlier...

I can't imagine why ClassName.class doesn't work on linux, but I'll update it since your way should work on all platforms.

Cheers for the info,

Kev

Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

ctomni231 (33 views)
2014-07-18 06:55:21

Zero Volt (29 views)
2014-07-17 23:47:54

danieldean (24 views)
2014-07-17 23:41:23

MustardPeter (26 views)
2014-07-16 23:30:00

Cero (41 views)
2014-07-16 00:42:17

Riven (43 views)
2014-07-14 18:02:53

OpenGLShaders (31 views)
2014-07-14 16:23:47

Riven (30 views)
2014-07-14 11:51:35

quew8 (29 views)
2014-07-13 13:57:52

SHC (64 views)
2014-07-12 17:50:04
HotSpot Options
by dleskov
2014-07-08 03:59:08

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:58:24

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:47:22

How do I start Java Game Development?
by ra4king
2014-05-17 11:13:37

HotSpot Options
by Roquen
2014-05-15 09:59:54

HotSpot Options
by Roquen
2014-05-06 15:03:10

Escape Analysis
by Roquen
2014-04-29 22:16:43

Experimental Toys
by Roquen
2014-04-28 13:24:22
java-gaming.org 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‑gaming.org
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!