Show a warning when you try to use a SurfaceAppearance while EnvironmentDiffuseScale/EnvironmentSpecularScale are both set to 0

As a developer, it is really easy to forget that you need to set both EnvironmentDiffuseScale/EnvironmentSpecularScale to 1 when working with SurfaceAppearance for Roughness/Metalness to work properly. I spent probably 30 minutes wondering what was wrong until it clicked that I forgot to set both to 1.

This isn’t the first time I’ve encountered this issue, either! I think I’ve made the same mistake a long time ago when SurfaceAppearances were first made available.

If this issue is addressed, then that would mean less people, especially new users, waste their time being confused about this issue in the future.

8 Likes