From the java3d-interest list:
Yaarq - Java3D Unleashed
http://swjscmail1.java.sun.com/cgi-bin/wa?A2=ind0212&L=java3d-interest&F=&S=&P=9681
Chess Board
http://swjscmail1.java.sun.com/cgi-bin/wa?A2=ind0212&L=java3d-interest&F=&S=&P=4904
From the java3d-interest list:
Yaarq - Java3D Unleashed
http://swjscmail1.java.sun.com/cgi-bin/wa?A2=ind0212&L=java3d-interest&F=&S=&P=9681
Chess Board
http://swjscmail1.java.sun.com/cgi-bin/wa?A2=ind0212&L=java3d-interest&F=&S=&P=4904
Looks nice (well, for Java…)
But - constant framerate?
Our system works basically like yours, but WakeupOnElapsedFrames(0) will never deliver constant framerates. Even the Sleep(1) doesn’t help. Maybe Sleep(20)? But I’m not sure wether it’s a good idea to Sleep() during a Behavior callback.
We headed for WakeupOnElapsedTime(30) and achieved quite smooth results. Additionally, judging from what I see in the demo, this would keep the CPU nearly idle.
Where does the bumpmapping get visible?
Hey,
Tried it out with the OGL version of j3d, and, well, no offense to the demo workers, or anything, but it looks kinda like Quake 1 level graphics (it reminded me of descent on my old 486 days), with decent lense flares. The frame rate was smoothe i was getting constant 60fps, but based on how the ship looked and such, it just seemed very blocky, like not alot of polygons were invovled. Would be nice if the scene had more curves to their shapes…I also saw no hints of reflections or bumpmapping. It’s a good first start, the models used just need to have a bit more detail to them. Not that I could do any better, I’m just saying…
-Chris
Framerate being high does not mean also that it’s constant! Even if the averaged number doesn’t vary. But small pauses from time to time (e.g. due to GC cylcles) make any animation unsmooth. Thats very typical for Java games and you can observe it in this demo very clearly.
Quake1: those days you couldn’t have fullscreen alpha polys - nowadays you can
did the test, the framerate looked quite constant, but with so few polygons, i would not expect less. Nevertheless, i think java3d has problems with radeon9000 cards. could not get any lighting. will have to test again with old demos to see if it goes better than this.
Herk: Yeah, there were definitely noticible GC pauses, maybe j3d wasn’t designed for animation, rather designed for clean OO-friendly scene modeling. Anyways, someone high up needs to put some serious work into eliminating garbage production (it seems). Here’s a question about J3D comming from someone who knows absolutely nothing about the API: when you create scenes and go through the culling process, etc, are temporary objects created and destroyed, or is it mostly doing set-oriented operations such as removing vertexes from the ‘visible set’ when it culls (but the vertexes themselves are not duplicated or deleted)? When you change a camera angle, is a new camera vector created or an existing one modified? When you do a scene rotation using a certain matrix, is the product of the matrix and scene generating new vertexes or modifying existing ones?
-Chris
I didn’t test the first one, but the chess board had problems with clipping since the chessboard didn’t clipped and the screen was filled with whacky outlines of the chessboard when it moved. Otherwise nice.
cknoll: I assume that Java3D actually does create objects while it is evaluating/sorting/rendering the scenegraph and I also think that this is absolutely ok. It’s definitely hard to have a complex OO system of arbitrary size getting along with static/preallocated memory. And it would require even more memory.
Captain-Goatse: seems the Background object is missing or misconfigured.
I tried the chess one, the effects were nice, still small frame delays tho. Also, Captian, if you let the demo run for a little while, you’ll see this “Jose” logo fly through, when that happens, the clipping region is widened and you don’t get that smearing effect fromt he board rotating (it takes about 45 secs for the logo to fly through) once that logo comes in, no more smear and the demo runs pretty well…I like the reflection effects and the lighting, and the marble looks very nice too…and the pieces are not blocky looking at all, very nice curves.
-Chris
Herk: Yeah, i’m not saying they shoudln’t be allocating memory, just being more paranoid about how it’s being used from frame to frame. I’m the first one to say “get it workin right, then get it workin fast” but they need to start puting considerible effort into optimizations (again, I’m just a outside observer punk giving his opinion). Based on what Prince says about certain things he has seen, I don’t htink my observation is too far off.
-Chris
I’ve tried with 1.4.1-fcs and 1.4.1_01 with Java3d and neither of these demos run for me. The java3d demos works fine with both JVMs.
They just hang and do nothing when I run them from the command line.
When I run the chess demo from the website I get errors like this:
Java VM version: 1.4.1_01
Java VM vendor: Sun Microsystems Inc.
KJAS: Error java.lang.NoClassDefFoundError: de/jose/Application during applet initialization
java.lang.NoClassDefFoundError: de/jose/Application
at de.jose.o.a(Unknown Source)
at de.jose.FlyBy.a(Unknown Source)
at de.jose.FlyBy.init(Unknown Source)
at org.kde.kjas.server.KJASAppletStub$2.run(KJASAppletStub.java:198)
at java.lang.Thread.run(Thread.java:536)
Has anyone been able to make this work under Linux?
Thanks.
I have tried the space demo. I’m impressed with the intro and it looks like a pretty cool interface.
However, I have 2 things to suggest. First, when you do the fullscreen exclusive mode, check to make sure thats available for the platform - I’m usuing linux and when I click on the hardware button - I get a bunch of exceptions halting the program - it should fail nicely telling me its not avaible.
2nd, I don’t get sound. This might be because I’m running linux but I haven’t looked at your code to tell.
Good job over all though
Just took a look at the yaarq one and it was quite impressive- a bit chunky windowed ( using the D3D java3d on a brand new P4 with an ATI rage pro 128- dismal card, but I don’t use 3d stuff much for work) and crashed altogether in j3d.dll when I tried fullscreen. Good to see some proper lens flares and the like, though.
I just downloaded your demo and started it.
Hardware Fullscreen doesn’t work correctly.
I can hear the music but nothing was rendered.
The other modes run, but I get only ~1FPS in fullscreen
and ~3FPS in windowed mode.
Your program tells me “1.1.0, missing, missing, failed[1]” (splash screen at startup).
I use Java SDK 1.4.1_01 and Java3D 1.3 under Win XP.
I’ve got a Athlon 1.4GHz, 256MB RAM, GForce 2.
Since I’m new to Java3D I’m quite impressed. Haven’t seen something similar yet!
But do I have some configuration-problem, or why is it running sooo slow?
Greetings, Adam.
[quote]Herk: Yeah, there were definitely noticible GC pauses, maybe j3d wasn’t designed for animation, rather designed for clean OO-friendly scene modeling. Anyways, someone high up needs to put some serious work into eliminating garbage production (it seems).
[/quote]
Java3d itself produces almost no garbage if used correctly. With non-so-trivial app I was able to cut it down to 2 objects allocated each frame inside java3d, both very small.
There is no object creation involved. In java3d, culling works on object-granularity, not on vertex/triangle.
Inside java3d, all of these objects are reused, so there is no allocation in library.
Hello all
Wolfgang Kienreich the author of Yaarq asked me to post this statements for him as he recently failed to get an account on java-gaming.org
original message:
Comments on your comments from the developer of Yaarq
First, let me thank you for your interest and let me apologize for not
earlier getting into this discussion, I am not a member of the forums on
java-gaming.org but that will soon change.
Regarding graphics, let me state that I had to do all the textures and
models for the demo on my own. While I appreciate critical review of my
artistical talent, I’m afraid I cannot spend days and months designing
sophisticated models and textures, so please do not judge the technical
side of Yaarq by model or texture quality. By the way, feel free to insert
new models into the demo, Yaarq is not simply an application but an engine
which easily accepts new media and behavior.
Then, for the hardware or driver problems some of you experienced: I have
tested Yaarq on a PIII with a GeForce2MX card, on a PIII with a GeForce4 TI
4200 card and on a Laptop PVI with a GeForce4 Go. I do not have ATI cards
avaiable (we try to avoid them due to their notoriously unstable drivers)
for testing and anyway, in a high-level lib like Java3D, I’m afraid I cannot
do a thing about driver problems.
Finally, for the framerate stabilisation: I do not pretend I have invented
the best and only method of doing things here. In a trial and error process,
I eliminated several approaches, from setMinFrameCycleTime to Behaviours,
and was left with the method implemented in Yaarq. The stalls occuring
during the first few seconds of the demo are normal, it takes time for the
3D framework to “warm up”. No stalls should occure (at least they didn’t
show up in my testings) once the demo has run for some time. Again, there is
nothing one can do about that, you can feel the warm-up effect even in
professional productions like Unreal Tournament.
Garbage collection stalls should not occure: I have spent some time in
designing the particel effects (which are the only parts of yaarq “creating”
lots of objects) to employ pooling techniques to avoid constant object
creation and destruction.
For more information on Java gaming performance, you will probably enjoy the
following paper …
http://www.rolemaker.dk/articles/evaljava/Evaluating%20Java%20for%20Game%20D
evelopment.pdf
… I found it competently written and of great use in designing Yaarq.
Thank you again for your interest in Yaarq, feel free to mail me in private
under nonlinear@aon.at or at work under wkien@know-center.at (again from
January 9th).
Wolfgang Kienreich
yaarq, and the chess demo work under Linux. The music works too.
It must have been me…
Anyway, great job! The chess and yaarq demos were both smooth as silk at about 50fps. With yaarq I was getting 50fps at 1600x1200 with a GeForce 2 in simulated full screen!
Note: I couldn’t tell the difference between simulated full screen and real full screen. Good job.
FYI: With a GeForce2 all of the yaarq features were found. With a TNT2 the dot3 bump mapping wasn’t there and the textures were black. With a 2D ATI using Mesa I received 0fps and a black screen LOL. (to be expected)
The chess demo only briefly shows the white pieces once and awhile - the rest of the time both sides are black. Really nice reflections.
Hi all,
I finally managed to get myself an account here, so I will be able to answer to questions regarding the Yaarq demo directly.
One important thing I forgot to mention in my answer to your comments: Yaarq is not yet finished, please contribute! In my original mail to the J3D interest group I explained in detail that I do not have time to do all the design and programming work necessary to fill the second part of the demo. Thats why you just get a plain dumb flyer and an empty sky to fly around. Try inserting objects, other flyers, clouds, whatever … and count on my support when doing so.
Best regards
Wolfgang
PS: Thanks to the guy who posted my first answer!
Hey Nonlinear !
Why did You break up Yaart’s model’s into different parts (big ship consists of 7 ? ) obj files ?
Does this bring any practical benefit ?
regards
Martin
I broke the models into one obj file per texture because (a) I encountered problems when loading multitexture obj files (texture coordinates got messed up) and (b) because I needed support for my additional texturing options like light/shadow map, environmental map and bump map, each of which requires its own additional special settings.
If someone starts working with the Yaarq engine, about the first thing to do is to write a little (xml-based?) model file format which takes this things into account, and some importers for lws, 3ds etc.
Cheers
Wolfgang