If you’ve done Web front-end visualization, WebGL, or GIS development, you’ve probably heard of Cesium. Cesium is an open source 3D GIS platform, using satellite maps, terrain, architectural white film, tilt photography, point clouds and other data to restore the real 3D earth. In my article on The official forum of Unreal on 28th May 2020-From Ants to Outer Space, the author used a very tricky way to simulate the scene of seeing the Earth From a small ant on the ground. Earlier Cesium provided the Javascript CesiumJS framework, and now Cesium for Unreal is officially released at 2021-03-30, which gives Unreal Engine the power of Google Earth and opens a new door for simulating the real world.
Cesium for Unreal Tutorial 01- Speed Start _ goippy-goippy-satisfactions analysis ロ Cheers ~- Bilibili www.bilibili.com This is a guide about using Cesium World Terrain and Cesium OSM Buildings quick start tutorial for Creating Cesium for Unreal apps. (translator’s note: basic unreal engine skills are required, and some C++ is preferred. For the basic skills of Unreal Engine, please refer to the official online learning tutorial) :
- First encounter with Unreal Engine
- Unreal Engine Primer
- Understand project and document structure
- Unreal Engine Editor Basics – Getting started with the editor
- Blueprint: Basic concepts
- Unreal Editor Basics – Materials
- Material: Basic concept
- Understand materials in visual design
- Convert blueprints to C++
Scenes of Seoul, South Korea, created with Cesium World Terrain and Cesium OSM Buildings in Unreal EngineYou will learn how to:
- Install the Cesium for Unreal plugin in Unreal Engine
- Add a level and import assets from Cesium Ion
- Add photo-level lighting effects in Cesium for Unreal
The preparatory work
- Install Unreal Engine (at least version 4.26 or above). For details on how to install Unreal Engine, visit the Unreal Engine Download page.
- A Cesium ion account for streaming terrain and building assets to Unreal Engine. If you don’t already have a free Cesium ion account, sign up for one.
Cesium Ion is an open platform for streaming and hosting 3D content, and contains global, accurate GIS data that can be used to create applications that represent a realistic 3D earth.
Step 1: Install the Cesium for Unreal plugin
If not already installed, install the Cesium for Unreal plug-in first.
- Open the Cesium for Unreal plugin page in the Unreal Engine marketplace.
- Log in to unreal Engine Store and click the Free button to install the plugin in Unreal Engine.
Step 2: Create projects and levels
- Start Unreal Engine and create a new project. Select the game on the Select Game Template screen.
Click on theThe next stepIn theSelect a templateInterface to selectblank. Other template types work as well.
在Project SettingsSelect theNo beginner content packTo avoid cluttering the level with unnecessary content. Select the new project path, modify the project name, and clickCreate a project.
- Activate the Cesium for Unreal plugin. Open the menuThe editor->The plug-inAnd then inThe plug-inSearch in the search bar in the upper right corner of the windowcesium. Make sure that the Cesium for Unreal pluginIs enabledThe check box is selected. After the plug-in is enabled, restart unreal Engine.
- Open the menufile->A new level, the choice ofcheckpoint.
- Open the menufile->Save the current level, select the storage path and name the new level QuickStart. For naming rules, please refer toUE4 Style Guide)
- Open the menuThe editor->Project Settings, and selectproject->Maps and Modes. willEditor starts the mapandDefault mapSet to QuickStart for the level you just created. This ensures that your level automatically reopens when you restart the Unreal Editor.
Step 3: Add SunSky Lighting and FloatingPawn
CesiumSunSky Blueprint adds cool sky sunlight lighting to outdoor scenes by extending the built-in SunSky blueprint to look exactly like sunlight on real Earth. Similarly, Cesium’s FloatingPawn extends the built-in FloatingPawn to allow it to move around the earth at will, and allows the use of a mouse wheel to control movement speed, especially useful when far from the ground (keyboard WSAD forward, left, right, mouse to control direction, and wheel to control movement speed). The camera should follow a curved path parallel to the earth’s surface, rather than a linear point-to-point trajectory, as the camera flies between different locations above Cesium earth. Cesium’s FloatingPawn does just that. It ensures that when you fly from one side of the earth to the other, you’re always pointing upwards from the center of the earth toward the sky.
- Go to Edit -> Project Settings and search luminance (or refer to the image below). Make sure the default brightness range option in the extended Auto Exposure Settings is enabled. If this option is not enabled, SunSky lighting will be fully exposed in direct sunlight, leaving the interface white. When this option is enabled, unreal Engine needs to be restarted.
- Click on theContent browserThe lower right corner of theView optionsAnd make sure both are checkedDisplay engine contentandDisplay plug-in content.
- inContent browser, click theChoose the pathButton, searchCesiumOr scroll down to find and clickCesiumForUnreal content.
- Drag the CesiumSunSky and FloatingPawn blueprints into the level viewport.
Step 4: Automatically have FloatingPawn at the start of the level
In the previous step, you added FloatingPawn to the level, but the player does not control it yet, and needs to perform the following steps to use it to move around the world.
- Select FloatingPawn in the World Outline View.
- Set up the game to start with Player 0 automatically controlling FloatingPawn: in the details panel, search for Heartheartness, click on the drop-down menu next to Auto-controlling Players, and select Player 0.
Step 5: Connect to the Cesium ion
- Open the Cesium panel by clicking the Cesium icon in the toolbar.
The Cesium panel will appear on the left side of the editor window.
- Click on theConnectButton to connect to Cesium ion. The browser will automatically open and ask you to allow Cesium for Unreal to access your assets using the currently logged account in Cesium Ion:
chooseAllowAnd return to Unreal Engine to continue.
Step 6: Create an Earth
In this step, you will populate the scenario with Cesium Ion’s assets.
- Open the Cesium panel by clicking the Cesium button in the toolbar. In Quick Add, click the plus sign to the right of Cesium World Terrain + Bing Maps Aerial imagery (feel free to Add one of the other Cesium World Terrain + Aerial combinations).
This step will be performed inWorld Outline ViewGenerate a newCesium World TerrainandCesiumGeoreferenceBlueprint object.
- There might be a black bar near the horizon. To resolve this problem, selectCesiumGeoreferenceIn object,detailsFound in panelSun SkyAnd then use the one you just createdCesiumSunSkyObject to initialize it.
Once theCesiumSunSkyObject connected toCesiumGeoreferenceObject automatically modifies its latitude and longitude properties to keep the Earth and sun in sync.
- If the scene is too dark, adjust itCesiumSunSkyOn the objectSolar TimeProperties, such as setting up a beautiful sunset scene. You may also want to change itTime Zone Time Zone.
For more information on how these properties work, visitSunSkyObject document.
Step 7: Add global 3D OSM Buildings to the scene
In this step, you will add Cesium OSM Buildings on top of Cesium World Terrain. Similar to Step 6, you will use the Cesium panel in the editor to add a new asset.
- Navigate back to the Cesium panel in Unreal Engine. Instead of using the Quick Add window as in the previous step, you will use the Cesium Ion Assets window to Add Cesium OSM Buildings. Click the Add button in the upper left corner to switch to the Cesium ion Assets window (which defaults to the lower left, on the right side of the Content Browser TAB). Here, you will see all the assets that exist in the Cesium ion account.
- chooseCesium OSM BuildingsAnd then clickAdd Add to Level.
Then you’ll seeCesium OSM BuildingsIt is now added toWorld Outline ViewIn the. ifCesium ion AssetsThere is noCesium OSM Buildings, please visitCesium OSM BuildingsAsset Repository page, and clickAddButton to add to my Assets. Then go back to Unreal Engine and shut it downCesium ion AssetsPanel, and then click againCesiumOn the front panelAddButton to reopen and refresh the asset list.
- If you can’t see buildings, then you’re probably in a place on Earth where there are no buildings. To navigate to a place on earth, visitWorld Outline ViewSelect theCesiumGeoreferenceIn object,detailsPanel, inCesiumFind the longitude of the origin under categoryOrigin Longitude, origin dimensionOrigin LatitudeAnd the origin heightOrigin HeightProperties.
Adjust these properties to the values you want. For example, the following building is located in Chicago, Illinois, USA, at -87.629799 in longitude, 41.878101 in latitude, and 2250.0 in height.
Set up theCesiumGeoreferenceAfter the origin, the editor camera will jump to there immediately. But, although the origin has changed, butFloatingPawnWill adjust itself to maintain its previous position on earth. When you click on therunButton when you want to start in ChicagoWorld Outline ViewSelected inFloatingPawn, set its position to (0,0,0).
- Click on the toolbarrunButton, then use the KEYBOARD W, A, S and D keys and mouse to roam the earth! With the mouse wheel can control the flight speed. When the camera is close to the ground, scroll down the mouse wheel to slow down. When the camera is far from the ground, scroll the mouse wheel up to increase your speed. In the editor, you can also change the camera movement speed with the control in the upper right corner.
The next step
Now you can add more assets and customize scenarios! Welcome to join QQ communication group: 517825387
Jq.qq.com/?_wv=1027&k… Cesium for Unreal Quick Start
All kinds of 3D knowledge will be updated from time to time, and there will be web3D articles to share. Welcome to pay attention and join the group to discuss. Our community webgpu.info/