Engine improvements: Prettier lighting with SeparateDiffuseTexture, cross-platform TCP client/server classes, EnablePhysics

Posted on

aluminium.x3dv_0

To finish the week of many annoucements, here are 3 more engine features added lately.

BTW, I also wrote a wiki page documenting common properties to “make rendering prettier”. Check it out:)

New engine features:

  1. Scene.Attributes.SeparateDiffuseTexture allows to get a prettier lighting behavior. The textures (in Appearance.texture or CommonSurfaceShader.diffuseTexture) will then really affect only the diffuse lighting term. This is generally better and prettier (specular highlights are then brighter), and it’s also more correct (according to X3D spec). But note that it is only possible in Phong shading (when Scene.Attributes.PhongShading is also true), and it makes rendering a little more expensive (for now).

    In view3dscene (see view3dscene from snapshots) you can use menu item View -> Separate Diffuse Texture (When Phong Shading) in addition to View -> Phong Shading on Everything. By default it is false, to be compatible with previous look, and also because it’s more consistent with Gouraud shading behavior. (And the Gouraud shading is default, in turn, for speed.)

  2. Client and server classes for implementing TCP client/server communication in Castle Game Engine games are available. See the unit CastleClientServer, and the demos in examples/tcp_connection. Thanks go to Benedikt Magnus for implementing this!

  3. You can now instantly disable/enable physics by setting SceneManager.Items.EnablePhysics to false/true.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.