question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

3D models, 3D Tiles, Point cloud crashing in Chrome on Android ('model_iblReferenceFrameMatrix' : undeclared identifier)

See original GitHub issue

3D models, 3D Tiles and Point clouds crash on some Android devices using Chrome or Chromium based browsers.

Testing the official examples from the Cesium Sandbox, they produce an error (fullscreen popup and in console) and stop working, making these features unusable if the target audience uses Chome on Android. The map itself loads and starts to fly the camera toward the example scene, but when it gets close enough to render the scene (3D model, point cloud), the error gets thrown.

Note that the following examples work on those same devices when using Firefox (106.1.0).

Devices I tested:

  • Samsung Galaxy S10e, Chrome 106.0.5249.118 (latest at the time of writing), Android 12
  • Huawei Nova 5T, Chrome 106.0.5249.118
  • Huawei Mate 20 Lite, Chrome 83.0.4103.106

Sandcastle examples:

https://sandcastle.cesium.com/index.html?src=3D Tiles Point Cloud.html Error log for 3D Tiles Point Cloud 3D Tiles Point Cloud.txt

https://sandcastle.cesium.com/index.html?src=3D Models.html Error log for 3D Models 3D Models.txt

https://sandcastle.cesium.com/index.html?src=CZML Model Articulations.html Error log for CZML Model Articulations CZML Model Articulations.txt

https://sandcastle.cesium.com/index.html?src=Cesium OSM Buildings.html Error log for Cesium OSM Buildings Cesium OSM Buildings.txt

https://sandcastle.cesium.com/index.html?src=Image-Based Lighting.html Error log for Image-Based Lighting Image-Based Lighting.txt

The Image-Based Lighting example shows an alert before starting (and crashing):

This browser does not support specular environment maps.

Some examples that do work: https://sandcastle.cesium.com/index.html?src=Clamp to Terrain.html https://sandcastle.cesium.com/index.html?src=Time Dynamic Point Cloud.html

Browser: Chrome for Android 83.0.4103.106 to 106.0.5249.118

Operating System: Android

Looks like all examples crash due to the same error:

Fragment shader failed to compile - 'model_iblReferenceFrameMatrix' : undeclared identifier

The only mention of this error I could find was #10833, but I would I would say this issue is not a duplicate, as it seems more Android phones are affected, not just HarmonyOS users.

Let me know if it would be helpful to have more results on which examples work and which don’t, and their error logs.

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
Marvosgcommented, Oct 17, 2022

@ggetz Thank you for the swift reply!

Confirming that adding the requestWebgl2 option works, the samples load and work the same as on other devices.

1reaction
j9liucommented, Oct 17, 2022

The crash is happening because there’s a function in ImageBasedLightingStageFS that always expects model_iblReferenceFrameMatrix to be defined. Even though this code isn’t traversed unless spherical coefficients / specular maps are used, the reference to model_iblReferenceFrameMatrix shouldn’t exist unless it explicitly uses either feature and there is browser support.

I’ll open a fix for this soon.

Read more comments on GitHub >

github_iconTop Results From Across the Web

ModelExperimental Sandcastle Testing #10379 - GitHub
3D Tiles Feature Styling fixed in Fix crash in 3D Tiles Feature ... Point cloud styling not showing up (GPU styling not implemented)....
Read more >
Point Clouds to 3D tiles - Google Groups
I am quite new to this, but I would like to know, how to convert .las or .pod to 3D tiles? Is there...
Read more >
3D Tiles Specification 1.0 - OGC Standards
Batched 3D Model; Instanced 3D Model; Point Cloud; Composite. This document also describes 3D Tile Styles, a declarative styling specification ...
Read more >
How 3D Tiles implements hierarc - OGC Portal
3D geospatial content, including photogrammetry/massive models, BIM/CAD, 3D buildings, instanced features, and point clouds, can be converted into 3D Tiles ...
Read more >
Introducing 3D Tiles - Cesium
To expand on Cesium's terrain and imagery streaming, 3D Tiles will be used to stream 3D content, including buildings, trees, point clouds, and ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found