The albedoSheenScaling constant is computed inside the light processing loop, so each next light overwrites the previous value and only the value from the last light is used. This means that depending on the order in which the lights are defined, the result will be different.
Furthermore, the resulting constant is then used to scale the emissive, diffuse and specular components. This means that direction of the last light will affect IBL and emissive components, which does not make a lot of sense.
I think the logic should be that albedoSheenScaling is only applied to the punctual lighting of the base layer of the same light. I don't know how IBL and Emissive should be handled. Probably the scaling should only depend on (n, v)
The
albedoSheenScaling
constant is computed inside the light processing loop, so each next light overwrites the previous value and only the value from the last light is used. This means that depending on the order in which the lights are defined, the result will be different.Furthermore, the resulting constant is then used to scale the emissive, diffuse and specular components. This means that direction of the last light will affect IBL and emissive components, which does not make a lot of sense.
I think the logic should be that
albedoSheenScaling
is only applied to the punctual lighting of the base layer of the same light. I don't know how IBL and Emissive should be handled. Probably the scaling should only depend on(n, v)