How to change the scale for box defined tilesets?

48 views
Skip to first unread message

mholt...@gmail.com

unread,
Mar 11, 2020, 10:59:05 AM3/11/20
to cesium-dev
1. A concise explanation of the problem you're experiencing.
I have a tileset which is defined with a box as boundingVolume. The tiles are displayed on the right place.
I want to use Matrix4.setScale() to update the scale of a tileset.

Using the code as shown in section 2 makes the tileset to disapper from the view area completely.
How can I apply a valid vertical exaggeration to the matrix of this tileset?

2. A minimal code example. If you've found a bug, this helps us reproduce and repair it.
Matrix4.setScale(
tileset.root.transform,
new Cartesian3(1, 1, scale),
tileset.root.transform
);

The default transform matrix here is:
Matrix4 {0: 1, 1: 0, 2: 0, 3: 0, 4: 0, 5: 1, 6: 0, 7: 0, 8: 0, 9: 0, 10: 1, 11: 0, 12: 0, 13: 0, 14: 0, 15: 1}

Setting the scale value to e.g. 1.9 this will be changed by the code above to:
Matrix4 {0: 1, 1: 0, 2: 0, 3: 0, 4: 0, 5: 1, 6: 0, 7: 0, 8: 0, 9: 0, 10: 1.9, 11: 0, 12: 0, 13: 0, 14: 0, 15: 1}

3. Context. Why do you need to do this? We might know a better way to accomplish your goal.
Update the scale of a tileset which contains a geoligical layer to apply vertical exaggeration.


4. The Cesium version you're using, your operating system and browser.
Cesium 1.67 & current Google Chrome


Reply all
Reply to author
Forward
0 new messages