Cesium-unreal as a git submodule in project

I have forked cesium-unreal and inserted it as a git submodule in my Unreal project which is the main project. After compiling (unsucccesfully), I realised that I need also cesium-native to make things work.

Should I add cesium-native as

a submodule of the Unreal project
as a submodule of the cesium-unreal ?

Also, should I compile cesium-native with cmake ? Isn’t Rider compiling the whole project for me ?

Dimitrios @ PrismArch project

When cloning the cesium-unreal repo, then this should be done recursively: It contains cesium-native as a submodule. The details are explained in the Developer Setpup (link for Windows). The relevant line should be

git clone --recursive https://github.com/CesiumGS/cesium-unreal.git

If you did not use the --recursive parameter when you first cloned it, then you can do a

git submodule update --init --recursive

to add the cesium-native submodule.

The linked documentation describes the further steps for compiling cesium-native. It indeed has to be compiled and installed separately (with CMake). But this should only have to be done once - after it is installed (and assuming that you don’t intend to make changes in cesium-native), you can develop in your project and cesium-unreal independently of that.

ok about the submodules.

About cmake:
I have followed the instructions for Visual Studio 2019 (cesium-unreal/developer-setup-windows.md at main · CesiumGS/cesium-unreal · GitHub) but Right-click on CMakeLists.txt gives the following errors:

Windows 10

Should I use cmake of VS or cmake from cmake.org ?


I have managed to compile it with cmake.org and

cmake -B build -S . -G “Visual Studio 16 2019” -A x64

I had to first delete all the contents in builds folder

Which folder should include in Rider ? It does not find Cesium3DTilesSelection folder
I have included the whole extern folder inside cesium-native

Sorry, I don’t know much about the specific include mechanisms for the Rider IDE. So I hope this is not a misunderstanding related to the word “include”:

After compiling cesium-native with CMake, you also have to install it. (This basically means: Copying the compiled libraries and headers into the cesium-unreal directory, so that they can be picked up).

Usually, this can be done with Visual Studio. Alternatively, you can do it on the command line. After executing the cmake -B build.... command that you mentioned, you can do a

cmake --build build --config Release --target install

(or --config Debug, depending on your goal).

Then, I think it should not be necessary to include anything manually in Rider (but again, maybe that IDE has its own intricacies, so we’ll have to see how that goes…)

An aside: Where does that #include "Cesium3D" in the screenshot come from? That shouldn’t be there…

Ok I have deleted every submodule related to Cesium because mixing Rider IDE with Visual Studio IDE was not a good idea. By using cmake.org and these two commands I have succeed to do the compile of cesium native ( I am also writing the paths for the execution because I got easily lost there :slight_smile: )

Plugins\cesium-unreal\extern>cmake -B build -S . -G “Visual Studio 16 2019” -A x64

Plugins\cesium-unreal\extern>cmake --build build --config Release --target install

I have got ThirdParty folder like this below. I assume that this is correct.

For some reason I get a yellow exclamation mark on Windows-x64 folder with the libs but I think it does play any role.