I hate finding out about these kinds of bugs late in the beta. But this one was pretty big.
X-Plane uses a "metalness" material model. Metalness is a fairly standard material model that recycles the albedo of your material to implement both dialectrics (non-metals) and metals. It works like this:
- Non-metal: diffuse light is tinted by the albedo texture. Specular light is not tinted.
- Metal: there is never diffuse light. Specular light is tinted by the albedo texture.
In other words, since metals don't have a diffuse component, we recycle the albedo to save texture space.
The bug in 11.05 is that for a pure metal, the albedo was tinting ambient light but not the sun itself. A third party developer sent me a test model that showed the problem - here's the before and after.
That weird set of colors on the top of the helicopter body is due to the white sunlight being added to the red body. The red aircraft body is lit by ambient light reflected directly off of the environment. The runway stripes are not visible because the metal is about 30% rough, diffusing the reflection.
(One of the confusing things about PBR models if you are not used to them is that the environment itself can cast both diffuse light and specular reflections off of a material, and if the material is rough, it can be hard to tell them apart. Diffuse light is always widely diffused, no matter how glossy the surface.)
Alex and I took a look at some of our legacy aircraft and found that fixing the lighting didn't make too much of a difference for metals that are not tinted.
Since our aircraft don't have any "tinted" metal there isn't much change. Note that in real life heavily tinted metals aren't common. The cases you might have are:
- Approximations of metals with complex spectrum-dependent fresnel like gold.
- Composite paint, e.g. like for your car, with fleks of metal and translucent dielectric polymer mixed together - that's the case where this really helps.
As I wrote this up I realized that the spot lights are still wrong in beta 8 - they'll be fixed for RC1 unless people really need the old model, in which case we'll have to put some versioning in. My guess though is that anyone doing composite paint realized it was impossible in 11.05 and hasn't shipped anything like that yet.
In these comparisons we are under an airport light viewing various materials. In the multi-color case the bottom row of materials are various "metals" with light tinting to simulate copper, iron, gold, etc.
In the second set of cases (all red) we have a 2-d grid: metal on the bottom, dialectric on top and rough on the left and glossy on the irght. Note that the reflection of the overhead light is reddish for the metals and white for the plastics in 11.10 (correct) but all white in 11.05 (incorrect).