I’ve made a custom 3DTile from an obj file with Obj2Tiles but when placed on the globe, the mesh is actually thousands of kilometers away from the origin.
It seems to be caused by a difference between the CRS used for the obj file and the one used by Cesium.
Is there any other CRS supported by Cesium on Unity other than ECEF ?
Cesium for Unity is based on the WGS84 ellipsoid and supports long / lat / height coordinates with respect to it. This is of course in addition to ECEF. I’m not personally familiar with Obj2Tiles—what CRS are they using? Perhaps there is a way to convert between the two.
I should mention that Cesium ion allows you to upload OBJ files and convert them to 3D Tiles. You could try to tile your model using Cesium ion, then geolocate it on the globe using Adjust Tileset Location. Then you can stream it into Unity from Cesium ion. I’d recommend trying this so we can confirm if it’s a matter of the input data being off, or the Unity scene setup resulting in this misalignment.
Either way, let us know and we can work from there.
Hi,
After a lot of research, it appeared that my problem wasn’t Cesium related. The vertices coordinates I got from my obj file were all wrong, this is why Obj2Tiles was creating a tileset this far away from everything else.
But now, I have another problem. The mesh can appear properly in Cesium Ion but doesn’t in Unity :
Picture of my mesh appearing correctly in Cesium Ion