As part of Bentley's commitment to keep evolving its solutions alongside the increasing complexity of the infrastructure industry, Bentley's cloud-based iTwin platform serves the central hub for bringing all elements of Digital Twins together in a collaborative, scalable environment which allows insights into all available types of data and planning stages of Digital Twins, including IoT, change tracking, maintenance and issue anticipation and much more. Together, all this data is known as an iTwin. Bentley's applications directly plug into the iTwin cloud platform, allowing all stakeholders to consume the Digital Twin from a single point of truth.
The iTwin for Unreal SDK enables streaming of iTwins and reality data from the iTwin cloud into Unreal Engine for high-fidelity visualization and consumption. Additionally, the SDK allows Unreal Engine developers to create custom applications which can expand upon the capabilities provided by the SDK out of the box. This enables the creation of tailored interactive experiences around iTwins. In addition, we provide a pre-compiled plugin version of the SDK.
The streaming technology is based on the open-source Cesium 3D tiles (link to the Cesium github) and offers great performance even with large datasets. The SDK is based on the experience gathered through the technology previews introduced by the Datasmith Connector and the 3DFT plugin during the last year.
The iTwin for Unreal SDK will supersede these technology demos and become the foundation of our upcoming advanced visualization products. It embodies Bentley's long-term commitment to offering scalable and future-proven technologies and open standards for any visualization needs of infrastructure and Digital Twins.
This SDK will be regularly updated. We appreciate your feedback to turn this exciting new technology into the leading foundation for advanced visualization of Digital Twins leveraging game engine technology. We encourage you to participate in the SDK's development with your ideas, requests and wishes, and help us shape the future of visualization together.
- Real-time 3D rendering, navigation and visualization of iModels with high performance; other iTwin related data will be added in future updates.
- Accessing saved views
- Exposed API for custom blueprints (for loading reality data, for example)
Please note that 4D animation is not part of this initial build, but it is one of our top priorities and will be added as soon as possible.
It is possible to load "external" tilesets (ie. non-iModels, like tileset coming from Cesium Ion server) by following these steps:
- Drag and drop an
ITwinCesium3DTileset
actor from the Content Browser into your level.
This actor can be found in the content browser inside folderPlugins/iTwin for Unreal C++ Classes/ITwinCesiumRuntime/Public
. - In the actor's Details panel, in the
Cesium
section, fill theSource
,Url
,Ion Asset ID
,Ion Access token
fields depending on the source of your tileset.
To use the iTwin plugin, you need to create an account at developer.bentley.com. There is a free 90 day trial available. The developer account is required for utilizing the streaming API within the plugin. If your trial period is over and you would like to continue using and testing the plugin, please get in touch with us.
This initial release supports Windows 11; Windows 10 might work, but has not been tested officially (you may conduct tests on Windows 10 yourself if you would like). A version for Mac is in development.
Only iModels and their Saved Views are supported at the moment; Reality Data can be loaded through blueprints only (no GUI is available in the ITwinTestApp for them at the moment).
Unreal Engine 5.3 is the currently supported version. Other Unreal Engine versions will be supported in future updates.
To run Unreal Engine, make sure you are using a dedicated GPU. The performance largely depends on the power of your graphics card. For more information on recommended system specs for Unreal Engine, please visit Epic's website.
We recorded a quick start video on YouTube. Read on for the written steps of the installation process.
- Go to the Releases page.
- Download ITwinForUnreal.zip from the latest release.
- Extract the zip archive to Unreal Engine's
Engine/Plugins/Marketplace
folder.
For example, on Unreal Engine 5.3 on Windows, this is typicallyC:\Program Files\Epic Games\UE_5.\Engine\Plugins\Marketplace
.
You may need to create theMarketplace
folder yourself.
After extraction, you should have a folderEngine/Plugins/Marketplace/ITwinForUnreal/Binaries
for example. - The plugin is now ready to use.
If you do not want to install the plugin in the Unreal Engine folder and instead prefer to put it directly in your Unreal project, just extract the zip archive inside your app's Plugins
folder (you may need to create this folder).
For example: C:\MyUnrealApp\Plugins\ITwinForUnreal
.
- If you installed the plugin in the Unreal Engine folder, enable the plugin
iTwin for Unreal
as explained here. - If not done yet, configure your iTwin Platform account and take note of your app's client ID.
- To access your iModels from your Unreal app, you will have to provide the iTwin app ID to the plugin.
This can be done in several ways:- Drag and drop an
ITwinAppIdHelper
actor from the Content Browser into your level.
This actor can be found in the content browser inside folderPlugins/iTwin for Unreal C++ Classes/ITwinRuntime/Public
.
Then, in the actor's Details panel, paste your iTwin app ID inside the fieldITwin/App Id
and validate.
Now, the plugin will use this app ID whenever this level is loaded.
This method is useful if you want to simply add an iModel manually into your level inside the Unreal Editor (see below). - If you use C++ code or Blueprint, you can instead directly call the static function
AITwinServerConnection::SetITwinAppID()
.
This is typically done in your app's moduleStartupModule()
function (if using C++), or in theBeginPlay
event of your Game Mode (if using Blueprints).
- Drag and drop an
- To manually add an iModel into your level inside the Unreal Editor, drag and drop an
ITwinIModel
actor from the Content Browser into your level.
This actor can be found in the content browser inside folderPlugins/iTwin for Unreal C++ Classes/ITwinRuntime/Public
.
Then, in the actor's Details panel, go to theLoading
section and fill in these fields:Loading Method
:Automatic
iModel Id
: the ID of your iModelChangeset Id
: the ID of the changeset you want to import Then the iModel should appear in the viewport. If the selected iModel/changeset has never been imported yet, the iTwin server needs to convert (ie. export) it into the Cesium format.
In such case the export will be automatically started, and the "Export Status" label will say "In progress" until the export is complete.
This can take a long time, depending on the complexity of your iModel. Once the export is complete, the iModel will appear in the viewport.
In an existing project which uses the 3DFT plugin
- Make sure your project is using Unreal Engine version 5.3.
See "Change a Project's Unreal Engine Version" here. - Remove the dependency to the 3DFT plugin. This is done by following these steps:
- If the 3DFT plugin folder is located inside your project:
- Make sure your project is not open in Unreal Editor.
- Remove the folder
Plugins\iTwin
from your project.
- If the 3DFT plugin folder is located inside in the Unreal Engine folder:
In the Unreal Editor, disable theiTwin
plugin as explained here.
- If the 3DFT plugin folder is located inside your project:
- Make sure your project is not open in the Unreal Editor.
- If not done yet, install the
ITwinForUnreal
plugin. - Remove the folders
Binaries
andIntermediate
that may exist at the root of your project's folder. - If your project contains C++ code, these additional steps are needed:
- Enable C++20 support; this can be done by adding/updating this line in your *.Target.cs files:
DefaultBuildSettings = BuildSettingsVersion.V4;
- Open your .uproject file in a text editor, and remove any dependency on module
iTwin
inside theModules/AdditionalDependencies
section. - Some classes have been renamed (eg.
AiModel
->AITwinIModel
), you may need to update your code accordingly.
Please refer to fileITwinForUnreal/Config/BaseITwinForUnreal.ini
for the list of changes.
- Enable C++20 support; this can be done by adding/updating this line in your *.Target.cs files:
- Modify your app so that it provides the iTwin app ID to the plugin, as explained in the "using the plugin in a new project" section.
Now, if you open your .uproject in the Unreal Editor, it should (build and) run without any error.
Create and configure your iTwin Platform account:
- Go to the iTwin Platform developer portal and create an account.
- Go to My Models and create a new iModel.
- Go to My Apps and register a new iTwin App:
- Application type: Native
- Redirect URIs: http://localhost:3000/signin-callback
Developer Mode for Windows must be enabled, as explained here.
- If not done yet, configure your iTwin Platform account and take note of your app's client ID.
- Configure your iTwin app ID in the plugin:
File: "\Public\CMake\main.cmake"
set (ITWIN_TEST_APP_ID "your_client_id_goes_here")
- Clone the vcpkg repo somewhere on your machine.
git clone https://github.com/microsoft/vcpkg.git
- Create an environment variable VCPKG_ROOT pointing to your local vcpkg repo. You can also set the VCPKG_ROOT as a cmake variable.
- Clone the repo and its submodules.
git clone https://github.com/iTwin/itwin-unreal-plugin.git
cd itwin-unreal-plugin
git submodule update --init --recursive
- Run CMake (command-line or GUI) and generate your build folder.
You need to select CMake preset "win64Unreal".
Command-line example, supposing current directory is your repo root:
cmake -S . -B C:\Build\itwin-unreal-plugin --preset win64Unreal
- Open ITwinTestApp.sln (in VS 2022) located inside the generated build directory.
- Hit F5 to build and run the test app (UnrealProjects/ITwinTestApp in the solution explorer).
- Once compilation is finished and VS has launched UnrealEditor, hit alt+P (play in editor) to actually start the app.
- remove your cmake Build folder
- call
git clean -dfX
in your source folder
- Packaging an application that uses both the iTwin plugin and the Cesium plugin will not work (errors about duplicate c++ symbols).
As a workaround, you can disable the Cesium plugin and add your tilesets as explained here.
We are looking forward to your feedback and your ideas for the plugin. If you encounter any bugs, please use the Issues tab to report any bugs.
Build 0.1.9 adds initial support for playing back 4D animations. Since this is an early access version, there are a few steps and limitations to consider. Please follow allong the following process:
- First, it is important to note that projects hosted in the East US region datacenter cannot yet access schedules data from the plugin, because of specific technical difficulties on these servers. This will of course be fixed in future builds.
You can see the region by scrolling down from the "Manage project details" panel.
- To be able to access schedules data, the project must have been resynchronized recently: projects not actively used and synchronized before mid-July of this year will probably need to be resynchronized, either by submitting actual changes to the project, or by changing any of the synchronization settings in the "Edit iModel" panel for the iModel bearing the 4D schedule:
- When "playing" an Unreal level and loading an iModel, the schedule data will be queried for all displayed geometries. After setting up the app Id and creating the iModel actor in your Unreal level, the geometries are immediately visible, but you need to play the level ("Play in Editor") for the 4D schedules to be enabled. Also, as a temporary workaround, after starting to play the level, you need to select the iModel and click "Update iModel": the tileset will be destroyed and re-created, and only then will the Schedule data start downloading.
This can take some time and you can see the pending queries in the "Output log" panel. Moving in the scene will stack more pending batches, when new tiles become visible or resolution changes occur. When waiting long enough, all pending queries will be handled, and a summary is visible in the Output log:
- Select the iModel in the Outliner, and select its Synchro4DSchedules component in the Details panel: you will see the Replay settings there, where you can:
*"Jump to beginning": jump to the start of the schedule (the default is a time far in the future in order to see the completed project)
*"Jump to end" of schedule
*Set the replay speed (in days of schedule time per second of replay time), or use "Auto replay speed" to fit the whole animation in 30 seconds of replay time.
*You can edit the "Schedule Time" field manually, to jump to a specific time point.
*"Play"/"Pause" the schedule animation
*"Stop" will pause the animation but also display all geometries with their original color and opacities, as if there were no schedules at all.
- There are also advanced Replay settings to optionally disable coloring, opacities or cutting planes during the animation, or to Mask out non-animated Elements which may be confusing when looking at the animation
(NOTE: that transformations and 3D paths are not supported yet - even if you uncheck the box)