This page has been translated automatically.
Video Tutorials
Interface
Essentials
Advanced
How To
Basics
Rendering
Professional (SIM)
UnigineEditor
Interface Overview
Assets Workflow
Version Control
Settings and Preferences
Working With Projects
Adjusting Node Parameters
Setting Up Materials
Setting Up Properties
Lighting
Sandworm
Using Editor Tools for Specific Tasks
Extending Editor Functionality
Built-in Node Types
Nodes
Objects
Effects
Decals
Light Sources
Geodetics
World Nodes
Sound Objects
Pathfinding Objects
Players
Programming
Fundamentals
Setting Up Development Environment
Usage Examples
C++
C#
UnigineScript
UUSL (Unified UNIGINE Shader Language)
Plugins
File Formats
Materials and Shaders
Rebuilding the Engine Tools
GUI
Double Precision Coordinates
API
Animations-Related Classes
Containers
Common Functionality
Controls-Related Classes
Engine-Related Classes
Filesystem Functionality
GUI-Related Classes
Math Functionality
Node-Related Classes
Objects-Related Classes
Networking Functionality
Pathfinding-Related Classes
Physics-Related Classes
Plugins-Related Classes
IG Plugin
CIGIConnector Plugin
Rendering-Related Classes
VR-Related Classes
Content Creation
Content Optimization
Materials
Material Nodes Library
Miscellaneous
Input
Math
Matrix
Textures
Art Samples
Tutorials

API Migration

Breaking Changes#

New HashMap/HashSet#

To improve performance and reduce memory consumption we have made some refactoring and optimization regarding Hash Maps and Hash Sets for this release. They both now store data linearly similar to vectors, which requires some changes in your code is case you have used them.

The findFast() method now returns a pointer instead of a double pointer:

UNIGINE 2.19 UNIGINE 2.19.1
ValueType **Hash::findFast(const KeyType &key) const
Source code (C++)
Unigine::HashMap<int, int> hash_map;
//...
auto item = hash_map.findFast(0);
if(item)
   Unigine::Log::message("%d\n", (*item)->data);
ValueType *Hash::findFast(const KeyType &key) const
Source code (C++)
Unigine::HashMap<int, int> hash_map;
//...
auto item = hash_map.findFast(0);
if(item)
   Unigine::Log::message("%d\n", item->data);

The emplace() method now returns an Iterator instead of a value:

UNIGINE 2.19 UNIGINE 2.19.1
ValueType &Hash::emplace(const KeyType &key)
Source code (C++)
Unigine::HashMap<int, int> hash_map;
Unigine::Log::message("%d\n", hash_map.emplace(0));
Iterator Hash::emplace(const KeyType &key)
Source code (C++)
Unigine::HashMap<int, int> hash_map;
Unigine::Log::message("%d\n", hash_map.emplace(0)->data);

HashMap vs BucketHashMap#

We've also kept the previous hash map implementation for backward compatibility and some specific cases, it is called BucketHashMap. Here is one of such examples, where the BucketHashMap must be used instead of the new HashMap - pointers to a key/value:

UNIGINE 2.19.1 - HashMap UNIGINE 2.19.1 - BucketHashMap
Source code (C++)
int *find(const HashMap<int, int> &hash_map, int key) {
	const auto &it = hash_map.find(key);
	if(it == hash_map.end()) return nullptr;
	return &it->data; //<-potentials crashes, use BucketHashMap
}
Source code (C++)
int *find(const BucketHashMap<int, int> &hash_map, int key) {
	const auto &it = hash_map.find(key);
	if(it == hash_map.end()) return nullptr;
	return &it->data; //<-everything is ok!
}

AnimationPlayback Class#

BootConfig Class#

CustomSystemProxy Class#

Decal Class#

Engine Class#

EngineWindowGroup Class#

New Functions

Input Class#

InputJoystick Class#

LightEnvironmentProbe Class#

LightOmni Class#

LightProj Class#

Log Class#

Material Class#

Materials Class#

UNIGINE 2.19 UNIGINE 2.19.1
compileShaders( ) Removed. Use CreateShaderCache( bool ) instead.

New Functions

ObjectParticles Class#

UNIGINE 2.19 UNIGINE 2.19.1
setLinearDamping( float ) Removed. Use getLinearDampingOverTimeModifier( ) instead.
getLinearDamping( ) Removed. Use getLinearDampingOverTimeModifier( ) instead.

New Functions

Profiler Class#

Render Class#

UNIGINE 2.19 UNIGINE 2.19.1
isQuadroSync( ) Removed.
setQuadroSync( bool ) Removed.
getTemporaryTexture( const Ptr<Texture> & ) Removed. Use getTemporaryTexture( const Ptr<Texture> &, const char *, Render::TEXTURE_ACCESSORY, Render::TEXTURE_LIFETIME, bool ) instead.
getTemporaryTexture( const Ptr<Texture> &, const char * ) Removed. Use getTemporaryTexture( const Ptr<Texture> &, const char *, Render::TEXTURE_ACCESSORY, Render::TEXTURE_LIFETIME, bool ) instead.
getTemporaryTexture( const Ptr<Texture> &, const char *, int ) Removed. Use getTemporaryTexture( const Ptr<Texture> &, const char *, Render::TEXTURE_ACCESSORY, Render::TEXTURE_LIFETIME, bool ) instead.
getTemporaryTexture( int, int, int, int, int, int, const char * ) Removed. Use getTemporaryTexture( int, int, int, int, int, int, const char *, Render::TEXTURE_ACCESSORY, Render::TEXTURE_LIFETIME, bool ) instead.
getTemporaryTexture( int, int, int, int, int, int ) Removed. Use getTemporaryTexture( int, int, int, int, int, int, const char *, Render::TEXTURE_ACCESSORY, Render::TEXTURE_LIFETIME, bool ) instead.
getTemporaryTexture( int, int, int, int, int, int, const char *, Render::TEXTURE_ACCESSORY, Render::TEXTURE_LIFETIME, bool ) Set of arguments changed.
getTemporaryTexture2D( int, int, int, int, const char *, Render::TEXTURE_ACCESSORY, Render::TEXTURE_LIFETIME, bool ) Set of arguments changed.
getTemporaryTexture2DArray( int, int, int, int, int, const char *, Render::TEXTURE_ACCESSORY, Render::TEXTURE_LIFETIME, bool ) Set of arguments changed.
getTemporaryTexture3D( int, int, int, int, int, const char *, Render::TEXTURE_ACCESSORY, Render::TEXTURE_LIFETIME, bool ) Set of arguments changed.
getTemporaryTextureCube( int, int, int, int, const char *, Render::TEXTURE_ACCESSORY, Render::TEXTURE_LIFETIME, bool ) Set of arguments changed.
getTemporaryOldTexture( const Ptr<Material> &, int, int, int, int, int, int, int, const char * ) Removed. Use getTemporaryOldTexture( const Ptr<Material> &, int, Texture, const char *, Render::TEXTURE_ACCESSORY ) instead.
getTemporaryOldTexture( const Ptr<Material> &, int, int, int, int, int, int, int ) Removed. Use getTemporaryOldTexture( const Ptr<Material> &, int, Texture, const char *, Render::TEXTURE_ACCESSORY ) instead.
getTemporaryOldTexture( const Ptr<Material> &, int, const Ptr<Texture> &, const char * ) Removed. Use getTemporaryOldTexture( const Ptr<Material> &, int, Texture, const char *, Render::TEXTURE_ACCESSORY ) instead.
getTemporaryOldTexture( const Ptr<Material> &, int, const Ptr<Texture> & ) Removed. Use getTemporaryOldTexture( const Ptr<Material> &, int, Texture, const char *, Render::TEXTURE_ACCESSORY ) instead.

New Functions

WallGroupData Class#

World Class#

Manager Class (IG)#

Entity Class (IG)#

Last update: 2024-12-13
Build: ()