# Rotate a Plane to face camera

**URL:** <https://community.cesium.com/t/rotate-a-plane-to-face-camera/25144>\
**Category:** CesiumJS\
**Created:** [July 4, 2023, 1:28am UTC](https://community.cesium.com/t/rotate-a-plane-to-face-camera/25144 "2023-07-04T01:28:42Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![gtk2k](https://sea2.discourse-cdn.com/cesium/user_avatar/community.cesium.com/gtk2k/32/11142_2.png) [@gtk2k](https://community.cesium.com/u/gtk2k)\
**Post date:** [July 4, 2023, 1:28am UTC](https://community.cesium.com/t/rotate-a-plane-to-face-camera/25144/1 "2023-07-04T01:28:42Z")

</div>

[Sandcasle](https://sandcastle.cesium.com/#c=dVRtb9owEP4rFvsSpGASIKXNaLWKlWnSuk4tq/YBaTLJAVadOLIdCpv47zvnpSTQRSLY9/rcc3eJZKoN2XJ4BUWuSQqvZAqa5wl9LmTOohMV96lMDeMpqEWn+3GRLtKo8MykRrfKZcqUwRNLh3SlZPIZ1gpAO/7wio5HwdgPxpeB7w0uXDIM6EUwvvL94SAYXFwGVy7xPc8GFmBIImMQ98wovjsGnyuW6pVUiabAtPkuldn8zOZyxncQzxRLwEEwNkSJTEdMwNG9DDcqgD1ZldOo9QjcQRjUK9C8/XVt0JMwSS4Mz8TeaWB1y5xuE3/JVckvjRCkYlSDseQ6fxcpITFow1NmuExDy6ZrhVJxQLqtkISksCufDbCYp2sUHvFsqJGPKEZ6HIvWPZpn3ESb/xr3sAstcyWFQGsMYmWHRXpotVqwFL6ATMCofXtWfjRVToV3C0jqboYdY6YJARRn4jbLgGFHI6DPd4/zu1+/Zw+P97dz9y1pK+1XPFnjdto6Y62tM68redjGXFXa7FgpYQYvyxxHoM12JIVUR/qm9nqa87b2LSarMGlNViHw7Sx5jVfQ7ZZpDmf1FvBO6FU84YZvzwqsQeiwTVNd1xvJYTPceQ+cZtFCaohDYlQOjdno941dQJFHOJkhWTGh2+qkihqS+lRVWE9YwnY8ycvlC+1meV7Z7Y7bmWizF3BTx/vEkwz3m+RKOJT2DSRYHranv8yjFzA00sWil8YfjJRiyVSzc0sWvayVzFMsRK2XzBkNXFL/PHp59MYlYbHdqZCMsl1DvJQqBtVTuCy5bisPZ6l5muWmCcAOP8dKe0zwNW52wuNYwHnWnpFZSAatzLVqKY2RSVtbpZ70m4RNYr4lPL5+51uN7WRao2aVC/HE/8CiczPpo/2Zq5DFp+UBkQu2t2Yb/+ZbKaSUTvp4fd+zIuEk8j8)  
I try this code. but does not face camera.  
How can I get it to work properly?

---

<div class="post-metadata">

**Author:** ![jjhembd](https://sea2.discourse-cdn.com/cesium/user_avatar/community.cesium.com/jjhembd/32/10144_2.png) [@jjhembd](https://community.cesium.com/u/jjhembd)\
**Post date:** [July 5, 2023, 10:07pm UTC](https://community.cesium.com/t/rotate-a-plane-to-face-camera/25144/2 "2023-07-05T22:07:03Z")

</div>

Hi @gtk2k, is there a reason why you are using the Primitive API? Primitives are low-level and harder to work with. The [Entity API](https://cesium.com/learn/cesiumjs-learn/cesiumjs-creating-entities/#what-is-the-entity-api) might be a better fit for what you are trying to do.

See [this thread](https://community.cesium.com/t/plane-normals-calculation-help/23878/2) for an example of how to construct a plane-shaped Entity.

---

<div class="post-metadata">

**Author:** ![gtk2k](https://sea2.discourse-cdn.com/cesium/user_avatar/community.cesium.com/gtk2k/32/11142_2.png) [@gtk2k](https://community.cesium.com/u/gtk2k)\
**Post date:** [July 6, 2023, 2:34am UTC](https://community.cesium.com/t/rotate-a-plane-to-face-camera/25144/3 "2023-07-06T02:34:03Z")

</div>

thank you for your reply.

The reason for using a Primitive is so that the Scale can be edited separately in X, Y and Z. This is because although Entity has Scale, it is impossible or difficult to set X, Y, Z separately.  
There is also readyEvent in Primitive (Model), but there is no equivalent in Entity.
