MODULE 4:
Immersive Environment Simulation: Adding Connext to the Visual Studio Build Environment
Add Connext to the Unreal C++ Build Environment
Next, we need to add Connext to the Unreal Visual Studio project build properties. This is done by adding the Connext dependencies to the <Project_Name>.Build.cs file in the Source\Unreal_Shapes of the project. For this example, we modify the Source\Unreal_Shapes\Unreal_Shapes.Build.cs as follows:
For accessing environment variables and constructing oaths, we need to use System and System.IO
using System;
using System.IO;
Connext uses runtime types and exceptions and so do the boost libraries. We need to enable support for those features in the build configuration.
bUseRTTI = true;
bEnableExceptions = true;
All items in the Connext directory will be relative to the install directory, which is defined by the environment variable NDDSHOME.
string nddshome = Environment.GetEnvironmentVariable("NDDSHOME");
Add the Connext additional include directories
PublicIncludePaths.Add(Path.Combine(nddshome, "include"));
PublicIncludePaths.Add(Path.Combine(nddshome, "include/ndds"));
PublicIncludePaths.Add(Path.Combine(nddshome, "include/ndds/hpp"));
Add Connext compile time options for Windows
PublicDefinitions.Add("RTI_WIN32");
PublicDefinitions.Add("RTI_STATIC");
PublicDefinitions.Add("WIN32_LEAN_AND_MEAN");
And finally, we need to add the libraries to link
PublicAdditionalLibraries.Add(Path.Combine(nddshome, "lib/x64Win64VS2017/nddscpp2z.lib"));
PublicAdditionalLibraries.Add(Path.Combine(nddshome, "lib/x64Win64VS2017/nddscz.lib"));
PublicAdditionalLibraries.Add(Path.Combine(nddshome, "lib/x64Win64VS2017/nddscorez.lib"));
If you are using a different operating system than Windows, the compile time options and library names will be different. Check the Platform Notes.
Module 4 Demo:
This video covers the steps for Module 4.