Author Topic: First beta of jPCT 1.18 released  (Read 2672 times)

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 11748
    • View Profile
    • http://www.jpct.net
First beta of jPCT 1.18 released
« on: April 01, 2009, 09:04:23 pm »
Hi,

here it is: http://www.jpct.net/download/beta/jpctapi_118pre1.zip

And here are the changes:

Quote
Added support for "compiling" Object3Ds for higher performance when rendering high polygon object. Fixed scaling of child objects (again...). Object3D.getWorldTransformation() now takes bill boarding into account. Added a method to OcTree to disable the usage of the octree for rendering. Changed default collision usage of octree from false to true. The 3ds-loader now loads transparency information. Setting a render target using frame buffer objects now uses the depth buffer correctly for the image rendered into the target.
Config.saveMemory is now true by default. The world's ambient light now defaults to 100,100,100 instead of -100,-100,-100. The purpose of negative light values is long gone with the legacy renderer being outdated. Fixed Object3D.getTransparency() for opaque objects. Added isTransparent() to Object3D.
Added the IRenderHook-Interface that can be used to execute own code in the pipeline of a compiled Object3D. Added two helper methods to the ShadowHelper that can be useful in an IRenderHook.
Improved overall OpenGL-renderer performance a little bit. Using a render target in the same scene that is rendered now works fine when using the single-threaded GLRenderer with FBOs. Added a setAlpha()-method to Texture.

As you may have noticed from some other threads, the biggest change is the option to "compile" an Object3D for higher performance when using the hardware renderers. I'll give a brief overview about this:

Advantages:
  • It's much faster than the default pipeline for higher polygon counts (up to 80times faster in my tests)
  • Shaders are possible for compiled objects by using the IRenderHook

Disadvantages/Limitations:
  • A compiled object can only use as many texture stages as the hardware offers. On current hardware, this means 4, on something like a GeForce2, it means 2. Anything higher will be discarded.
  • Only the 8 nearest light sources will affect the lighting, not all lights
  • Config.lightMul is implicitly set to 1 for a compiled object
  • environment mapping is done in world space only

Some words about using compiled objects: Basically, all objects can be compiled, even animated ones. There are two modes. One for static objects, one for dynamic ones (animated, manipulated by an IVertexController....). The static mode is much faster than the dynamic one...which may still be faster than the default pipeline but that depends.
There are few more things to consider...some are already mentioned in the javadocs, others may be missing. In case of doubt, just ask here...

Have fun!

Offline fireside

  • double
  • *****
  • Posts: 605
    • View Profile
Re: First beta of jPCT 1.18 released
« Reply #1 on: April 02, 2009, 05:43:36 am »
Nice job Egon.  The game I'm working on now was designed for software but I might try a small parallel hardware project to try it out.   
click here->Fireside 7 Games<-

Offline JavaMan

  • long
  • ***
  • Posts: 231
    • View Profile
Re: First beta of jPCT 1.18 released
« Reply #2 on: April 03, 2009, 12:36:53 am »
Awesome Egon! This is great you got a beta out so soon after announcing the news. I played a little last night, but I will get some real time tomorrow night! I'm so excited. (duh)
« Last Edit: April 04, 2009, 02:28:44 am by JavaMan »

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 11748
    • View Profile
    • http://www.jpct.net
Re: First beta of jPCT 1.18 released
« Reply #3 on: April 03, 2009, 08:05:32 am »
It's beta (and not alpha), because everything that i throw at it works fine now. That doesn't mean, that everything out in the wild will work...