I am trying to style my 3D tiles according to the 3D Tile Style spec. However, I am struggling with getting it to look the way I want. Specifically, when using Cesium3DTileStyle, I am finding that the colors are coming out very washed out and “dull” looking, and the material loses much of its specular highlights / reflectivity, as compared to when I don’t rely on Cesium3DTileStyle and simply use the material colors that I hardcode into the model. Even though the colors I specify are exactly the same in both cases, the result looks very different.
Here is a comparison of what the colors look like when I set them directly via glTF material, versus when I specify the same colors via 3D Tile Style:
Notice the specular highlight from the sun, and the (relatively) vibrant colors in the first version.
In the second version, I set the time of day to be the same and aligned the camera view as closely as possible. I specified the same colors via 3D Tile Style, and yet the result appears much more “dull” looking. The material has the same metallic/roughness parameters, except I replaced it with pure white in glTF.
You can also compare these examples live here:
V1 (glTF material):
V2 (Cesium 3D Tile Style):
Any idea why the result looks so different? And is there anything I can do to restore some of the “luster” that was lost when moving to Cesium 3D Tile Style?
I suspect this may have something to do with color blending. I saw documentation for the colorBlendMode property on Cesium3DTileset, which suggests that by default it will blend the color from the material with the color specified in Cesium. Which might explain why it looks a bit “washed out” in the second example, since it’s blending pure white with the actual color I want. I’m not sure if that’s how it works, I’m just speculating here… but based on that, I tried a couple more things.
First I tried setting the property to REPLACE instead of HIGHLIGHT, but it didn’t have any effect. I did see the documentation for Cesium3DTileColorBlendMode, which says that to use REPLACE, you need to set the
_3DTILESDIFFUSE semantic. It wasn’t entirely clear, but after doing a little more research, it appears this semantic applies if you’re using the KHR_materials_pbrSpecularGlossiness extension.
So I modified the glTF generation process to use that extension, and also tried adding the “techniques” key to my glTF model. I’m not entirely sure if I did that part right, since I didn’t see this
techniques property in the glTF 2.0 spec - I just added it to the root of the model, but not sure if that’s where it goes. But that didn’t seem to have any effect.
Anything else I could try?