Waiting for the sales team

I shared this information in my last post.

It seems like you want the radius of the earth in Unity space (as opposed to real-world measurements), so you’d need to account for the scale you assigned to CesiumWorldTerrain. Use the CesiumWgs84Ellipsoid functions to get the real-world radii of the ellipsoid, then scale it by the factor you’re using to resize the globe.

Yes, i got it but i don’t know how to call that fonction, CesiumWgs84Ellipsoid is not recognize.

Did you add using CesiumForUnity; to the top of the file?

Yes, i add it, the thing is, sorry i’m a beginner in unity, how can i get the x radius for example ? Do i just have to do : float xrad = CesiumWgs84Ellipsoid.GetRadii(x) ?

Is there any possibility to have an access to some documentation about those fonction :


Because i am not able to ctrl click on it.

Thanks a lot for your answer.

How did you get to that page? It definitely seems like there should be documentation there, or at least some comments when you hover over the function names.

In any case, you can find the CesiumWgs84Ellipsoid and other scripts in the Packages/Cesium for Unity/Runtime folder. Everything that is public API will have comments on it.

The GetRadii returns a double3, which is documented here.

I went here by doing a ctrl click on CesiumWgs84Ellipsoid in my code:
image
I found the documentation, thanks, i was wondering how to get the height ?

I have another question about the LongitudeLatitudeHeight … fonction, if my scale of my Cesium world terrain is like 0.5 and not 1, this fonction will give the coordinate for that scale (0.5) or for the basic scale (1) ? Not sure if you will understand me

The longitude, latitude and height coordinates are never impacted by the Unity scale of the globe. These are geospatial coordinates, so it doesn’t make sense to scale a longitude or latitude by 0.5.

If you want to adjust the height value for the scale of the globe, you have to factor that in yourself. Alternatively, you can just set the scale of the game object containing the CesiumGeoreference, so that all of its children are affected.

Ok, so for the good of my project i had to put this value :
image
I’m not sure to understand what i have to change :


Multiply this one ?

I tried several things , i will try to be quite clear, i have this lat, long and height in entry :
image
And when i use the fonction, i got this in output :
image
I don’t understand why its here, because when i put in on my earth, my object is in oceania instead of being in france.

If you’re trying to place an object your best bet is to attach a CesiumGlobeAnchor to the object, then set the longituteLatitudeHeight on it with your desired coordinates. See this tutorial for more details. Placing Objects on the Globe – Cesium

I’m confused about what you’re trying to do, because the LongitudeLatitudeHeightToEarthCenteredEarthFixed transforms coordinates in longitude + latitude + height to ECEF coordinates. They are NOT the same as Unity coordinates.

I also advise that you don’t do anything different with the earth coordinate math. Instead, let the CesiumGeoreference and CesiumGlobeAnchor components handle the transforms.