Development news: Beautiful shader rendering, compositing shaders extensions, shadow maps, Blender X3D exporter mods, and more
We have some great news about the recent engine developments. As always, remember that you can try all the new features immediately by downloading a binary from our nightly builds!
We have a new shiny method of rendering everything through shaders (OpenGL Shading Language, aka GLSL). All of the standard X3D rendering features, as well as our extensions, are available in this rendering mode. This results in much better look of many scenes.
By default, the shader rendering is used only for shapes that require it — shapes that are shadow map receivers, use bump mapping, or have an explicit shader source code assigned (by the ComposedShader node, or by the new Compositing Shaders extensions). For testing purposes, you can switch to "View -> Shaders -> Enable For Everything" in view3dscene menu. The results should be the same (or better) than current renderer.
All the lighting is calculated per-pixel in shader rendering (we use the Phong shading). This is targeted at high-end GPUs anyway, so for now I decided that there's no point in making alternative per-vertex lighting (Gouraud shading). This means you should expect much nicer specular and spot light highlights. Try to make some smooth and curvy metallic surfaces to appreciate it :)
Note that shapes that don't need any shader effects are still by default rendered through the fixed-function pipeline. So the performance of simple scenes should not suffer on low-end GPUs.
Our bump mapping effect is very nicely unified within the new rendering process. Previously we used special bump mapping shaders, limited to common situations. Now bump mapping works under all lighting and texturing conditions, and takes all normal VRML/X3D lights into account.
We also make bump mapping "enabled" by default.
Our bump mapping works also with two-side lighting now.
The shadow maps implementation is also nicely unified with new rendering. This gives a huge improvement, as now we take into account the shadows in the correct place of the lighting equation, scaling down only the contribution of the obscured light. So the shadows maps work fully correctly with multiple lights and multiple shadow maps over the same shape.
Shadow maps also work now with all the multi-texturing possibilities. And, in general, they work with every VRML/X3D lights/materials/textures settings.
New "View -> Shaders" submenu allows to choose when shaders are used:
Note that this all in development right now. There are some rough edges for now, that will be fixed before the next release, in particular:
Another big news is our compositing shaders extensions. The short introduction to our "compositing shaders" idea is here, including the screenshots and information where to find the demo models.
I wrote a paper about this that will be submitted for the Web3D 2011 conference, and will be available here publicly later (I don't think I should make it public before being accepted). Drop me a mail if you'd like to get a peek at my paper PDF earlier.
"Kambi VRML test suite" will be renamed to "VRML / X3D demo models" upon the next release. The SVN already has many improvements:
compositing_shaders
demos, testing our extensions for compositing shaders.papers/shadow_maps_x3d/
subdir in SVN, which wasn't well known.Blender VRML/X3D exporters page updated, I added there a modified version of Blender 2.56 X3D exporter, fixing small things, and adding exporting of normalMap (for our bump mapping extension).
For developers using FPC 2.2.4 (or older): a bug slipped into the last engine sources, preventing compilation with FPC 2.2.4 or older. A fixed version of the sources is released, see FPC version notes and engine sources. Thanks to Stephen H. France for reporting this!
view3dscene has new File -> Preferences persistent settings for line width (controls all line visualization, like wireframe, bounding box, LineSet
etc.), point size and default background color.
VRML 1.0 PerspectiveCamera.heightAngle
and OrthographicCamera.height
support.
Shadow maps PCF 4 bilinear fixes — it was too dark.
Copyright Michalis Kamburelis and Castle Game Engine Contributors.
This webpage is also open-source and we welcome pull requests to improve it.
We use cookies for analytics. See our privacy policy.