A tick-tock release cycle allows easy migration to new software versions. Obsolete code is marked as deprecated for one major release. Deprecated code produces compile-time warnings. These warning serve as notification to users that their code should be upgraded. The next major release will remove the deprecated code.
- The major version has been removed from the cmake project name and the
package.xml package name. Use
find_package(gz-common)instead offind_package(gz-commonX)going forward.
gz::common::MovingWindowFilteris deprecated since the functionality was moved to gz-math. Please usegz::math::MovingWindowFilterinstead.
- Logging has been heavily modified as we're relying on spdlog. See example1 and example2 to learn how to access the internal spdlog logger and the global options.
The gzdbg, gzmsg, gzlog, gzwarn and gzerr macros should work the
same as previous versions but you now have two extra macros: gzcrit and
gztrace for logging critical errors and traces respectively.
Console::SetVerbosity only accepts values between 0 (critical errors only)
and 5 (all log messages). Other values don't have any effect.
- Removed the
graphicscomponent's dependency on the GTS (GNU Triangulated Surface) library which was used for doing triangulation and CSG Boolean operation by theMeshManager. The Delaunay triangulation function now uses the CDT (Constrained Delaunay Triangulation) library.
- MeshManager.hh
void CreateBoolean(const std::string &_name, const Mesh *_m1, const Mesh *_m2, const int _operation, const gz::math::Pose3d &_offset = gz::math::Pose3d::Zero)
Submesh::MaterialIndexis deprecated.SubMesh::GetMaterialIndexshould be used instead, which properly handles submeshes having no material index applied to them.- The
ignitionnamespace is deprecated and will be removed in future versions. Usegzinstead. - Header files under
ignition/...are deprecated and will be removed in future versions. Usegz/...instead. - The logging macros (
ignmsg,ignwarn,ignerr, etc.) and logging function macros (ignLogInit(), etc.) are deprecated and will be removed in future versions. Usegzinstead (e.g.gzmsg,gzwarn,gzLogInit()) - All the plugin APIs are deprecated, use the gz-plugin library instead. See the migration guide.
- The following
IGN_prefixed environment variables are deprecated and will be removed. Please use theGZ_prefixed versions instead!IGN_VIDEO_ALLOWED_ENCODERS->GZ_VIDEO_ALLOWED_ENCODERSIGN_VIDEO_ENCODER_DEVICE->GZ_VIDEO_ENCODER_DEVICEIGN_VIDEO_USE_HW_SURFACE->GZ_VIDEO_USE_HW_SURFACEIGN_FILE_PATH->GZ_FILE_PATHIGN_LOG_PATH->GZ_LOG_PATHIGN_PLUGIN_PATH->GZ_PLUGIN_PATH
- The following
IGN_/IGNITION_prefixed macros are deprecated and will be removed in future versions. Additionally, they will only be available when including the correspondingignition/...header. Use theGZ_prefix instead.IGN_ENUMIGN_HOMEDIRIGN_NANO_TO_SEC,IGN_SEC_TO_NANO,IGN_MS_TO_NANO,IGN_US_TO_NANOIGN_SPEED_OF_LIGHTIGN_SLEEP_S,IGN_SLEEP_US,IGN_SLEEP_MS,IGN_SLEEP_NSIGN_SYSTEM_TIME,IGN_SYSTEM_TIME_S,IGN_SYSTEM_TIME_US,IGN_SYSTEM_TIME_MS,IGN_SYSTEM_TIME_NSIGN_ASSERTIGNITION_COMMON_TINYOBJLOADER_IMPLEMENTATION(srclocal, hard-tocked)IGN_PROFILER_ENABLE,IGN_PROFILE_THREAD_NAME,IGN_PROFILE_LOG_TEXT,IGN_PROFILE_BEGIN,IGN_PROFILE_END,IGN_PROFILE_L,IGN_PROFILE,IGN_PROFILE_VALIDIGN_CREATE_SPEC_INTERFACEIGN_DUMMY_PLUGIN_PATHIGNITION_UNITTEST_SPECIALIZED_PLUGIN_ACCESS
- The
Image::Data(unsigned char**, unsigned int&)functions that accept a pointer and a size and internally allocate memory are deprecated and will be removed in future versions. Use the newDatafunctions that return astd::vector<unsigned char>to have automatic memory management.
- The project name has been changed to use the
gz-prefix, you must use thegzprefix!
- This also means that any generated code that use the project name (e.g. CMake variables, in-source macros) would have to be migrated.
- Some non-exhaustive examples of this include:
GZ_<PROJECT>_<VISIBLE/HIDDEN>- CMake
-configfiles - Paths that depend on the project name
- geospatial component that loads heightmap images and DEMs
- Depends on the gz-common's
graphicscomponent and thegdallibrary
- Depends on the gz-common's
-
HeightmapData.hhandImageHeightmap.hhhave been moved out of thegraphicscomponent and into the newgeospatialcomponent- To use the heightmap features, users must add the
geospatialcomponent to thefind_packagecall and update the include paths to use the geospatial subfolder (#include <ignition/common/geospatial/HeightmapData.hh>)
- To use the heightmap features, users must add the
-
HeightmapData::FillHeightmapmethod is nowconst. -
Image::AvgColor,Image::DataandImage::RGBDatamethods are nowconst.
-
Corrected
BAYER_RGGR8toBAYER_BGGR8inPixelFormatNameandPixelFormatTypelocated ingraphics/include/gz/common/Image.hh. -
URI parsing has updated to follow the specification more closely when
URI::Authorityis set. Changes include:- An empty URI Path is valid.
- Double forward slashes,
//, are valid in a URI Path. - A URI Query does not require a
key=valueformat. For example a valid query can be "?aquery", "?aquery?", and??. - A URI authority is optional. If present, then a URI authority begins with two forward slashes and immediately follows the URI scheme. A host must be present if an authority is present and the scheme != 'file'.
-
Event.hh
- Added second template argument to
EventTto disambiguate events with matching signatures.
- Added second template argument to
-
profiler component that helps measure software performance.
-
SystemPaths.hh
- Search paths specified in
GZ_FILE_PATHenvironment variable when finding files.
- Search paths specified in
-
Util.hh
- Added
constexpr uint64_t hash64(std::string_view)to generate a hash at compile time if possible.
- Added
-
Depends on gz-cmake2
- gz-common now depends on gz-cmake2.
-
Requires c++17.
-
(New in 3.8.0) On Windows, the value of C++ macro
GZ_HOMEDIRchanged fromHOMEPATHtoUSERPROFILE. It is usually used to read the path to the user's home from environment. The old value pointed to a path relative to the (a) current drive letter as reported bypwd, not the system drive letter. The new value correctly points to an environment variable that contains the full absolute path to the user's profile. If the code did not use the macro in some unexpected way, the new behavior should work either the same or even better (it would work even when the current directory is on a non-system drive). If the code relied on this value to be relative to the current drive letter, it needs to be changed to useHOMEPATHdirectly.
-
Depends on gz-cmake1
- gz-common now depends on gz-cmake1, which provides support for Component libraries.
-
Component libraries
- Some classes have been moved from the main gz-common library
to component libraries. To use these features, you must
list them in the
find_packagecall and link against them.- av: audio and video playback and encoding
- events: registering and handling event callbacks
- graphics: animation, images, and triangle meshes
- Some classes have been moved from the main gz-common library
to component libraries. To use these features, you must
list them in the
- gz-cmake
- gz-math now has a build dependency on gz-cmake, which allows cmake scripts to be shared across all the Gazebo packages.