Skip to main content

I have created a workspace that converts shapefiles (.shp) into Cesium 3D Tiles using the Cesium3DTiles writer. It works pretty well but I'm wondering if I can control how my geometries are broken up into tiles.

 

I've played around with the area and volume calculator to set the cesium_priority property to control when tiles should appear at different zoom levels but I see tiles that span the whole US for instance and I want to sub divide the tile based on a grid or maybe an attribute. Is something like that possible?

 

This picture shows a volume that spans the US that may have some geometries on the west and east coast. Instead I may want a tile for the west coast and another tile for east coast at this zoom level. I can provide my workspace if needed. Thanks!

 

2021-08-27_14-09-15

Yeah more control over 3D tiles would be great. For now I think the only thing you can really do is try and sort the data based on their extent.

In the writer you can configure the number of features per tile and it just writes them out in the order the features are received. If you're able to sort the data into a grid beforehand this should help to reduce the size of the tiles. You can also reduce the number of features per tile as well​


Thanks for the guidance! This sounds promising. I'm looking to the 3D Tiles writer and I don't see where I can configure the number of features per tile. Can you point me how to do this?

parametersattributes


Nevermind! I found that you can only set the number of features when creating a writer. Doesn't seem like you can change it once the writer is created.


Nevermind! I found that you can only set the number of features when creating a writer. Doesn't seem like you can change it once the writer is created.

Yeah that's right, it's a fixed number but depending on the complexity and density of the features lowing the number can help even the spread​


I've got it configured pretty well. I limit the features per tile to 15 and used a spatial sorter to order the features by location. I then used a volume calculator to set the cesium_priority property to control LOD. My last issue is that some tiles still load when zoomed out. For instance, I tested a single tile with 15 features and the bounding box that was created is much bigger than the features in it. If the box covered only the extents of the 15 features it would only load when I zoomed in much closer. When I have thousands of these large tiles loading at this zoom level the performance decreases.

 

bounding


I've got it configured pretty well. I limit the features per tile to 15 and used a spatial sorter to order the features by location. I then used a volume calculator to set the cesium_priority property to control LOD. My last issue is that some tiles still load when zoomed out. For instance, I tested a single tile with 15 features and the bounding box that was created is much bigger than the features in it. If the box covered only the extents of the 15 features it would only load when I zoomed in much closer. When I have thousands of these large tiles loading at this zoom level the performance decreases.

 

bounding

Nice to hear. Are you able to pin point what is causing these larger bounding volumes? Could it be possible that a feature with really high/low priority is somehow effecting the volume? I don't use the cesium_prioitry myself so I'm not too sure how much of an effect it has.


Nice to hear. Are you able to pin point what is causing these larger bounding volumes? Could it be possible that a feature with really high/low priority is somehow effecting the volume? I don't use the cesium_prioitry myself so I'm not too sure how much of an effect it has.

Good suggestions. I experimented with that same data from above and this is what I found.

 

I set the features per tiles to 1 so that I would end up having 15 tiles.

First I made each have a different cesium_priority by using a counter. In the picture below, the first tile to appear has the highest priority (14) and a huge bounding volume.

highPriorityAs you zoom in, other tiles start to appear and the bounding volume loosely relates to the priority. It seems likes some tiles have the same bounding volume

lowPriority 

My final test was to again have 1 feature per tile but set the priority of all features to zero. Here it choose one feature it display first with a huge bounding volume and the remaining features show up when you zoom in closer with much smaller volumes. This seems to be the best option so far.

zeroPriority


Nice to hear. Are you able to pin point what is causing these larger bounding volumes? Could it be possible that a feature with really high/low priority is somehow effecting the volume? I don't use the cesium_prioitry myself so I'm not too sure how much of an effect it has.

I still think the bounding volume for a single feature is larger than it needs to be and titled on an axis for some reason. Maybe that has something to do with the coordinate system.


Hello @kteneyck​! Our Dev team is working on improving the 3D tiles writer for the 2022.0 release. This will include an option to limit the number of faces per tile, rather than the current option.


Hello @kteneyck​! Our Dev team is working on improving the 3D tiles writer for the 2022.0 release. This will include an option to limit the number of faces per tile, rather than the current option.

Glad to hear there are improvements coming! Its the main reason I'm evaluating FME right now and generating an efficient 3D Tile would be the deciding factoring on whether to purchase a license.

 

Do you know if there would also be any appearance/styling improvements? For instance, I want to style an outline between all the faces of the feature. Something like this

f43c2b487de2ec77074d2e8e58c36b618c1df1e1


Hello @kteneyck​! Our Dev team is working on improving the 3D tiles writer for the 2022.0 release. This will include an option to limit the number of faces per tile, rather than the current option.

I'd also be wiling to privately share the input shapefiles and FME workspace if that would be helpful


Glad to hear there are improvements coming! Its the main reason I'm evaluating FME right now and generating an efficient 3D Tile would be the deciding factoring on whether to purchase a license.

 

Do you know if there would also be any appearance/styling improvements? For instance, I want to style an outline between all the faces of the feature. Something like this

f43c2b487de2ec77074d2e8e58c36b618c1df1e1

Hi @kteneyck​ - not to take away any business from FME, you should buy it regardless because it's just awesome, however, if you work at all with CityGML we have a pretty good CityGML converter to 3DTiles which supports this styling. If you are at all interested to try it out feel free to contact me. I think my email and our website is listed on my Community profile.


May I know whether this issue is resolved or not? Thank you so much!

 

https://community.safe.com/s/question/0D54Q000080heWgSAI/bounding-volume-of-tiles-in-cesium-3d-tiles


Reply