Crash when adding silhouette to GLTF model

1. A concise explanation of the problem you're experiencing.

I have a gltf model that works excellent, until I try to add a silhouetteSize to it. I receive this error:

[Cesium WebGL] Vertex shader compile log: ERROR: 0:21: 'a_normal' : undeclared identifier
ERROR: 0:21: 'normalize' : no matching overloaded function found
ERROR: 0:21: '=' : dimension mismatch
ERROR: 0:21: '=' : cannot convert from 'const mediump float' to 'highp 3-component vector of float'

[Cesium WebGL] Vertex shader translation failed.
An error occurred while rendering. Rendering has stopped.
undefined
RuntimeError: Vertex shader failed to compile. Compile log: ERROR: 0:21: 'a_normal' : undeclared identifier
ERROR: 0:21: 'normalize' : no matching overloaded function found
ERROR: 0:21: '=' : dimension mismatch
ERROR: 0:21: '=' : cannot convert from 'const mediump float' to 'highp 3-component vector of float'

Error
    at new RuntimeError (https://cesiumjs.org/Cesium/Build/CesiumUnminified/Cesium.js:3857:19)
    at createAndLinkProgram (https://cesiumjs.org/Cesium/Build/CesiumUnminified/Cesium.js:94535:23)
    at initialize (https://cesiumjs.org/Cesium/Build/CesiumUnminified/Cesium.js:94740:23)
    at ShaderProgram._bind (https://cesiumjs.org/Cesium/Build/CesiumUnminified/Cesium.js:94757:9)
    at beginDraw (https://cesiumjs.org/Cesium/Build/CesiumUnminified/Cesium.js:171285:23)
    at Context.draw (https://cesiumjs.org/Cesium/Build/CesiumUnminified/Cesium.js:171347:9)
    at DrawCommand.execute (https://cesiumjs.org/Cesium/Build/CesiumUnminified/Cesium.js:90539:17)
    at executeCommand (https://cesiumjs.org/Cesium/Build/CesiumUnminified/Cesium.js:236570:21)
    at executeCommands (https://cesiumjs.org/Cesium/Build/CesiumUnminified/Cesium.js:236934:17)
    at executeCommandsInViewport (https://cesiumjs.org/Cesium/Build/CesiumUnminified/Cesium.js:237347:9)

Note that the model passes this validator: http://github.khronos.org/glTF-Validator/

2. A minimal code example. If you've found a bug, this helps us reproduce and repair it.

A SandCastle using the model that generates the error:

3. Context. Why do you need to do this? We might know a better way to accomplish your goal.

Adding a "halo" around the model, to help make it more visible.

4. The Cesium version you're using, your operating system and browser.
Cesium 1.54 in the sandcastle, Cesium 1.48 locally. Chrome 72.0.3626.96 (Official Build) (64-bit) on Ubuntu 18.10.

Looks like it’s because one of the primitives in this glTF does not have normals. I opened a GitHub issue with some more details here:

https://github.com/AnalyticalGraphicsInc/cesium/issues/7586

Thanks for reporting this!

Thanks for looking at this so quickly.

This is my first foray into working with 3D models; are the normals added during the conversion from COLLADA to GLTF (e.g. an option I didn't correctly set in the conversion pipeline), or do they need to be present in the source model (which I've created with Blender).

Thanks!

I’m not entirely sure. What did you use to convert your model to glTF? If I had to guess I’d say the normals aren’t present in the source model. So I’d look up how to view the normals in Blender and start there.

I was able to use Blender to get the normals added.

Once the normals were in blender, I also found that I had to export to OBJ rather than DAE in order for the GLTF converter hosted by CesiumJS.org output a gltf file that I was able turn the sihouettes on for.

Thanks for your help, Omar.