When I render a kml file from local system to Google Earth, it is rendering properly, keeping in mind the altitude from ground, the terrain and the outline and fill of the polygon in kml file. But when I upload the same kml file to cesium ion, and render it from there, it is not rendering properly. The outline is getting thin in 2D and when I change to 3D terrain, the outline is not visible.
I’m not able to pinpoint the issue here. I’ve tried rendering it on different application, but it’s the same issue. It works properly when rendered from local system, but it gives issue when rendered from cesium ION.
It would be much appreciated if anyone can help with this.
The above images show the screenshots when the kml file is rendered from cesium ION.
It should look like below when properly rendered(Uploaded to Google Earth from local system).
Hi,
I wasn’t able to reproduce your exact issue with the thin outlines. Are you able to provide a sandcastle link?
When I was trying to recreate the issue in sandcastle, I did see a message in the console:
Entity geometry outlines are unsupported on terrain. Outlines will be disabled. To enable outlines, disable geometry terrain clamping by explicitly setting height to 0.
Thank you for looking into the issue.
I’ve seen your sandcastle. You can see the filled tiles are stable are all are clamp to ground but the unfilled tiles are unstable and they are not on clamp to ground.
I’m facing same issue. The solution is needed is how can I apply clamp to ground on the tiles which are not filled. So they can stick to the terrain.
I’m going to transfer this to the CesiumJS category since it appears to be related to CesiumJS rendering clamped KML and not an issue with Cesium ion streaming the data.
In my angular application, I’m using cesium js package. When I import kml in my application(Local) its working properly but when I import kml file to cesium ion it looks like the same as your given sandcastle example. Please giude me if I’m doing anything wrong.
Below given is the kml file I’m using
testkml.kml (16.9 KB)
I’m a bit confused because you first mentioned you were talking about Google Earth being different from Cesium ion, but now you mentioned that it is an AngularJS application using CesiumJS that is showing the differences when loading locally vs from ion.
It would help to be better explain the issue if you were able to provide:
- An image from your AngularJS application using CesiumJS when loaded locally
- An image from your AngularJS application using CesiumJS when loaded from Cesium ion
- What are the differences you are having issues with (is the the line weight or the clamping, or both?)
- An image from Angular v13 application using CesiumJS when loaded locally. Note: I’m enabling Cesium World terrain
==============================================================================
- An image from Angular v13 application using CesiumJS when loaded from Cesium ion
Image when WGS84 Ellipsoid is enabled
Image when Cesium World Terrain is enabled
From the above images we can see
When the KML file loaded locally on CesiumJS it worked fine when enabling Cesium World terrain and even we can see the given width to the lines.
But when the same KML file is loaded from cesium ion
1: I tried with enabling WGS84 Ellipsoid. We can see the lines are thinner
2: When I tried with enabling Cesium World Terrain. We can see the particular line thing goes below the terrain.
I’m also attaching kml file which I’m using
testkml.kml (16.9 KB)
Here is a sandcastle with the asset loaded from ion and the correct line weight.
There is a know issue with CesiumJS polygon outlines not properly classifying terrain. That is preventing the polygons from appearing projected on the terrain.
Your example also appears to be using different code when you load locally compared to from Cesium ion because the local example has labels in the view and the ion version does not. There could be difference in that code that causes the line weights to be displayed differently. Without access to your application code there is no way to know that. In the future the best way to get help debugging an issue is to create a sandcastle that reproduces the issue. That way everyone can reproduce the issue and see the code that causes the problem.
I tried the sandcastle code that you provided and it is still not rendering the asset with correct line width for me.
So if the same sandcastle is rendering differently for us that indicates that it is probably a bug in the CesiumJS rendering code.
Are you able to provide the operating system browser version version you are using? For reference I am viewing on Linux with Chrome Version 120.0.6099.129.
I am viewing Windows 10 OS and the Chrome Version is 120.0.6099.130
I also tried it on a linux system, and on that, I am able to see the correct line weight, but the clamp to ground issue still persists. When the Cesium World Terrain is enables, we are not able to view the grid as it goes below the terrain.
I have opened an issue for our team to track the line weight problem: KML lineweights render different · Issue #11748 · CesiumGS/cesium · GitHub
When the Cesium World Terrain is enables, we are not able to view the grid as it goes below the terrain.
This is probably because the lines are set a a height below the terrain.
The height (altitude) is set to 0. This problem is occurring only on cesium when enabling World Terrain, as on google earth it’s rendering perfectly.
Thank you for your support regarding line weight.
Could you please inform me about the expected timeline for resolving this issue? Also, will it be addressed in the upcoming Cesium version?