# \[C++\] How to place/transform an actor ? (which coordinates ?)

**URL:** <https://community.cesium.com/t/c-how-to-place-transform-an-actor-which-coordinates/14897>\
**Category:** Cesium for Unreal\
**Created:** [August 18, 2021, 3:54pm UTC](https://community.cesium.com/t/c-how-to-place-transform-an-actor-which-coordinates/14897 "2021-08-18T15:54:05Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Gregory\_S](https://sea2.discourse-cdn.com/cesium/user_avatar/community.cesium.com/gregory_s/32/4929_2.png) [@Gregory\_S](https://community.cesium.com/u/Gregory_S)\
**Post date:** [August 18, 2021, 3:54pm UTC](https://community.cesium.com/t/c-how-to-place-transform-an-actor-which-coordinates/14897/1 "2021-08-18T15:54:05Z")

</div>

Hello,

I would like, in C ++, to place objects in a Cesium scene in Unreal Engine from coordinates sent in DIS.

Example:  
GetWorld () → SpawnActor (MyHelicopterReference, Location, Rotation, SpawnParameters);  
// How to compute location? in which space?

How can I do ? Do the coordinates of the object have to be in Unreal’s world coordinate system?

I saw that there is a TransformLongitudeLatitudeHeightToUe () function. Can it be of use to me and how do I use it? Is it possible to have access to cesium classes in our c++ project ?

---

<div class="post-metadata">

**Author:** ![Nithin\_Pranesh](https://avatars.discourse-cdn.com/v4/letter/n/ecd19e/32.png) [@Nithin\_Pranesh](https://community.cesium.com/u/Nithin_Pranesh)\
**Post date:** [August 19, 2021, 3:20pm UTC](https://community.cesium.com/t/c-how-to-place-transform-an-actor-which-coordinates/14897/2 "2021-08-19T15:20:48Z")

</div>

Hello @Gregory_S,

You can retrieve a pointer to the `ACesiumGeoreference` actor by using the static `ACesiumGeoreference::GetDefaultForActor` function. On this actor you can find the `TransformLongitudeLatitudeHeightToUe`, `TransformEcefToUe`, and other useful conversion functions.

Currently your input coordinates need to be in WGS84 longitude/latitude/height or Earth-Centered, Earth-Fixed (ECEF).

Let me know if anything isn’t clear!

Thanks,  
Nithin Pranesh

---

<div class="post-metadata">

**Author:** ![Gregory\_S](https://sea2.discourse-cdn.com/cesium/user_avatar/community.cesium.com/gregory_s/32/4929_2.png) [@Gregory\_S](https://community.cesium.com/u/Gregory_S)\
**Post date:** [August 20, 2021, 3:21pm UTC](https://community.cesium.com/t/c-how-to-place-transform-an-actor-which-coordinates/14897/3 "2021-08-20T15:21:14Z")

</div>

Hi,

Maybe my question is stupid, but how can I get access to the Cesium plugin in my c ++ code?

#include \<CesiumGeoreference.h\> is not accessible

I added “CesiumRuntime” in MyProject.Build.cs:  
PublicDependencyModuleNames.AddRange (new string {“Core”, “CoreUObject”, “Engine”, “InputCore”, “CesiumRuntime”});

Is there anything else to be done?

---

<div class="post-metadata">

**Author:** ![Gregory\_S](https://sea2.discourse-cdn.com/cesium/user_avatar/community.cesium.com/gregory_s/32/4929_2.png) [@Gregory\_S](https://community.cesium.com/u/Gregory_S)\
**Post date:** [August 25, 2021, 7:35am UTC](https://community.cesium.com/t/c-how-to-place-transform-an-actor-which-coordinates/14897/4 "2021-08-25T07:35:42Z")

</div>

It works after several compilations and restarts
