Is there a way to move the Polygon entity?

150 views
Skip to first unread message

max....@gmail.com

unread,
Jun 11, 2019, 1:30:47 AM6/11/19
to cesium-dev
1. A concise explanation of the problem you're experiencing.

Is there a way to move the Polygon entity?
https://cesiumjs.org/Cesium/Build/Documentation/PolygonGraphics.html

I’ve made the function to move the point entity before, but no knowledge or idea to move the Polygon entity.


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


3. Context. Why do you need to do this? We might know a better way to accomplish your goal.
To make it easier to move the Polygon entity.


4. The Cesium version you're using, your operating system and browser.

ces...@1.57.0

Hieu Nguyen

unread,
Jun 11, 2019, 2:27:05 AM6/11/19
to cesium-dev
hi,  this is an example for your question  http://embed.plnkr.co/OaXj7euFYLXfKwZOmSMx/

Vào 12:30:47 UTC+7 Thứ Ba, ngày 11 tháng 6 năm 2019, max...@gmail.com đã viết:

max....@gmail.com

unread,
Jun 11, 2019, 3:16:24 AM6/11/19
to cesium-dev
Hi, thanks for the quick reply.
does it work properly??
it doesn't show any entities on my chrome...

2019年6月11日火曜日 15時27分05秒 UTC+9 Hieu Nguyen:
スクリーンショット 2019-06-11 16.15.18.png

Hieu Nguyen

unread,
Jun 11, 2019, 3:42:09 AM6/11/19
to cesium-dev
i dont know why demo does not working  but code still work. let try insert function "disableCameraMotion" and function "movePolygon" to your code.

Vào 14:16:24 UTC+7 Thứ Ba, ngày 11 tháng 6 năm 2019, max...@gmail.com đã viết:

Omar Shehata

unread,
Jun 12, 2019, 3:18:01 PM6/12/19
to cesium-dev
To move a polygon, you need to recompute the PolygonHeirarchy positions. This forum post has an example on doing this to rotate, but moving should be the same idea:

max....@gmail.com

unread,
Jun 17, 2019, 8:58:28 PM6/17/19
to cesium-dev
OK, thanks.
And finally, I've made it!!!
moved the polygon entity!!
wooohoooo :)))))

2019年6月11日火曜日 16時42分09秒 UTC+9 Hieu Nguyen:

max....@gmail.com

unread,
Jun 17, 2019, 8:59:11 PM6/17/19
to cesium-dev
2019年6月13日木曜日 4時18分01秒 UTC+9 Omar Shehata:
Thanks for the additional info!!
Reply all
Reply to author
Forward
0 new messages