Content Migration
You can upgrade content of your project to UNIGINE 2 in the automatic or manual mode.
Automatic Upgrade
Automatic upgrade of the project's content can be performed via Unigine SDK Browser:
- Add the project to the SDK Browser. If there is no *.project file in the project folder, it will be generated automatically on the basis of the specified data.
- Click the Upgrade available label or Other Actions -> Configure Project.
- Specify a path to a folder where the backup project will be saved (if required).
- Click Upgrade.
The binary executable files, meshes, terrains, worlds, nodes, splines and materials will be upgraded to new formats.
Manual Upgrade
To upgrade the project's content in the manual mode, do the following:
- Add the project to the SDK Browser. If there is no *.project file in the project folder, it will be generated automatically on the basis of the specified data.
- Click the Upgrade available label or Other Actions -> Configure Project.
- Specify a path to a folder where the backup project will be saved (if required).
- Uncheck Upgrade content and click Upgrade. The binary executable files will be upgraded.
- Put the binary executable <UnigineSDK>/bin/usc_x64.exe (or <UnigineSDK>/bin/usc_x86.exe) to the <UnigineSDK>/utils/Upgrade folder that contains the upgrade script.
- From this folder, run the upgrade.usc script as follows:
Here:
usc_x64.exe upgrade.usc <unigine_project/data path/to/the/additional_content_1 path/to/the/additional_content_2 ...
- <unigine_project/data - a path to the content stored in the project folder.
- path/to/the/additional_content_* - paths to folders with content stored outside the project folder. Specify here all paths specified as arguments of the extern_path startup command-line option).
As a result you will get your meshes, terrains, worlds, nodes, splines and materials upgraded.
Meshes and Animation
Both static and animated meshes are now stored in a .mesh file format. It can store both geometric data (vertices and their weights) and animation (bone transformations and blend shapes).
As before, skinned meshes can be stored together with animation data in a .mesh file, or animation data can be stored without geometry in a separate .anim file that is used instead of the old .sanim format.
Moreover, the updated mesh file format also features:
- Up to 7 active blend shapes (morph targets) per surface for facial animation and object deformations.
- Different kinds of mesh animation (scaling, morphing, addition, subtraction) before skinning.
- Support for multiple named animations.
- Seamless tangent space between different surfaces.
- Storing of pre-calculated tangent space from 3D editors.
- Bone rotations stored in quaternions instead of normal vectors for better loading speed.
- A bind pose for each mesh. The first animation frame shouldn't contain the bind pose as before.
- Support for 8-bit vertex colors.
- Increased precision for texture coordinates (controlled by a half_texcoords SCons flag, a half precision is set by default).
- Support for unsigned short and double (OpenGL only) vertex formats for dynamic meshes.
- Unlimited vertex count for dynamic meshes.
- Increased precision of the Z coordinate to 32-bit float.
- Two sets of per-spatial vertex and per-triangle vertex indices. Such an approach improves the loading speed.
- Increased precision for skinning to 32-bit float weights.
- Extended animation layers API with all of the animation buffers functionality. Animation buffers have been removed.
- The same set of shaders for static and skinned meshes.
See also the articles on the new and old mesh file formats:
Terrain
The format of .ter files has been changed in UNIGINE 2. The new terrain features are the following:
- Precision for height maps has been increased to 31 bits, floating point (1 bit is used for holes).
- Added additional uncompressed index texture that stores a number of a detail material per channel (can have up to 16 channels).
- Detail materials have been renamed to Layers.
- Added specular texture to layers.
- Added ability for flexible mask setting by modifying Value, Width and Threshold parameters.
- Added parent-children system, which allows you to use the same mask for several materials.
- Added 8 performance levels for 1, 2, 3, 4, 6, 8, 12, and 16 materials (shaders for other amount of materials are not ready yet).
- Added diffuse, normal and specular terrain texture arrays. They are recalculated automatically on terrain materials changing while editing.
See also the articles on the new and old formats:
Materials and Material Libraries
In UNIGINE 2, the format of a .mat file, the list of available materials and material libraries, the set of material options have been changed.
Material Libraries
The following default material libraries has been removed in UNIGINE 2:
- unigine_mesh_layer.mat
- unigine_mesh_lut.mat
- unigine_mesh_noise.mat
- unigine_mesh_overlap.mat
- unigine_mesh_paint.mat
- unigine_mesh_shadow.mat
- unigine_mesh_tessellation.mat
- unigine_mesh_tessellation_paint.mat
- unigine_mesh_triplanar.mat
Materials
In the upgraded project, there will be the following changes in materials:
UNIGINE | UNIGINE 2 |
---|---|
mesh_indirect_base | Removed. The mesh_base material is now used instead. |
mesh_layer_base | Removed. The mesh_base material is now used instead. |
mesh_lut_base | Removed. The mesh_base material is now used instead. |
mesh_lut_reflection_cube_base | Removed. The mesh_base material is now used instead. To create reflections, use reflection probes. |
mesh_noise_base | Removed. The mesh_base material is now used instead. |
mesh_overlap_base | Removed. The mesh_base material is now used instead. |
mesh_paint_base | Removed. The mesh_base material is now used instead. |
mesh_paint_reflection_cube_base | Removed. The mesh_base material is now used instead. To create reflections, use reflection probes. |
mesh_base | The name remains the same. However, internally, this is a new physically based material. You can use the specular workflow that works with the standard of textures used in the old mesh_base material. |
mesh_pbr_base* | If you already use this material in your project, it will be renamed mesh_base after upgrading to UNIGINE 2. |
mesh_reflection_2d_base | Removed. The mesh_base material is now used instead. To create reflections, use reflection probes. |
mesh_reflection_cube_base | Removed. The mesh_base material is now used instead. To create reflections, use reflection probes. |
mesh_reflection_fresnel_base | Removed. The mesh_base material is now used instead. To create reflections, use reflection probes. |
mesh_shadow_base | Removed. The mesh_base material is now used instead. |
mesh_tessellation_base | Removed. The mesh_base material is now used instead. |
mesh_tessellation_indirect_base | Removed. The mesh_base material is now used instead. |
mesh_tessellation_paint_base | Removed. The mesh_base material is now used instead. |
mesh_tessellation_paint_reflection_cube_base | Removed. The mesh_base material is now used instead. To create reflections, use reflection probes. |
mesh_tessellation_reflection_2d_base | Removed. The mesh_base material is now used instead. To create reflections, use reflection probes. |
mesh_tessellation_reflection_cube_base | Removed. The mesh_base material is now used instead. To create reflections, use reflection probes. |
mesh_tessellation_reflection_fresnel_base | Removed. The mesh_base material is now used instead. To create reflections, use reflection probes. |
mesh_triplanar_base | Removed. The mesh_base material is now used instead. |
decal_deferred_base | Removed. The decal_base material is now used instead. |
decal_terrain_base | Removed. The decal_base material is now used instead. |
Material States
All rendering passes has been removed for all materials.
As a consequence, the following options of these materials have also been removed:
- Ambient light is removed from grass_base, grass_impostor_base, mesh_leaf_base, terrain_base.
- Phong shading is removed from mesh_leaf_base.
The LightProb and LightSpot rendering passes have been removed from all materials.
The other changes on states of materials:
- volume_fog_base: Multisample option.
Worlds and Nodes
Light Sources
The following light objects have been deleted:
Decals
The following changes have been made on decals:
UNIGINE | UNIGINE 2 |
---|---|
DecalObjectOrtho DecalTerrainOrtho DecalOrtho |
DecalOrtho |
DecalObjectProj DecalTerrainProj DecalDeferredProj |
DecalProj |
DecalDeferredMesh | DecalMesh |
In UNIGINE 2, you can set a decal mask for a material