jPCT - a 3d engine for Java > Projects

tokima

(1/5) > >>

acorn98:
www.tokima.com uses the jPCT API. It's up and in beta - enjoy.

EgonOlsen:
Looks great and proves that simple vertex-lighting can still produce very nice results. However, i noticed two issues while running around in the level: There's some Z-fighting when polygons overlap. But that's a "problem" with the model, not with the code. It's not that bad anyway.
I assume it's somehow based on the fps-demo? If so, on which version? Older versions did the actual movement in the timer-thread and with the upgrade to a P4 with Hyperthreading, i noticed that this isn't a good idea, because it leads to threading issues (like when the timer-thread is working on a rotation-matrix the main-thread uses for rendering). This results in parts of the geometry rendered wrong or distorted for a frame. And this is exactly what i noticed when running around in the level. Note that i never experienced this on none-HT CPUs like Athlons, so it's difficult to explain and debug. Have a look at the newer version of the fps-demo to see how i'm doing it now. As a rule of thumb: Never let any other thread than the main-thread (the thread that does the rendering) modify the camera or some object's matrices. Not the timer-thread and not an Event-Listener-thread (like a Key- or Mouse-Listener) because you may run into trouble. And it's a real pain to debug this stuff...believe me... :wink:
But now back to running around in this world... :D

acorn98:
Thanks for the feedback - very handy. There's some bad poly overlap in places, mainly due to my abilities with 3dsMAX - I'm still getting to grips with it. My next effort should be considerably cleaner.

Yes, it's an fps adaptation - I can't remember which version exactly, but I think it was from around mid December. I don't have the source with me but I suspect I may have modded the camera in a mouse listener, and there are probably a variety of other coding misdemeanours! I'll revisit the code and improve it.

My next step is to get networking in there for multiplayer. I've got some old code somewhere which should do the trick, and it'll make the thing much more interesting.

...by the way - that fps source was fantastic. I'll fix the site up and add a proper credit to JPCT.net  :wink:

EgonOlsen:

--- Quote from: "acorn98" ---There's some bad poly overlap in places, mainly due to my abilities with 3dsMAX - I'm still getting to grips with it. My next effort should be considerably cleaner.
.......by the way - that fps source was fantastic.
--- End quote ---
Yes...i noticed that there seems to be one (or some) large polygon below the street's actual polygons which "shines through" due to inaccuracies in the zBuffer (caused by the nature of it...nothing i can do about it). That's causing most of the z-fighting problems and it hurts fillrate and the octree. You should try to get rid of it IMHO.
The newer versions of the fps-code are even better... :wink: (No multi-threading issues anymore).
Keep up the good work. I really like the mood of this level.

acorn98:
There were a couple of places where I had some gaps between street objects that I couldn't fix easily, and I found that the sky background was bleeding through. To patch it, I threw in a big plane under the street to block it off - I'll see about patching it properly.

Also, I have a couple of very long fences with a tiny repeating texture which seems to warp into a diagonal line - I think it started happening when I stretched the object to its current length (which is pretty big). Is it a bug, do you think?

I'll grab your latest fps source and have a look through, and remodel mine accordingly. I sometimes get the odd frame which flashes, which I
figured was down to the threads getting in a bit of a mess.

I wanted to make something quite dark and oppressive - I'll keep adding to it (work permitting) and see what develops.

Thanks for the tips!

[/quote]

Navigation

[0] Message Index

[#] Next page

Go to full version