Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ign -> gz Namespace Migration : gz-rendering #629

Merged
merged 28 commits into from
May 29, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
892c93d
Update header guards
methylDragon May 18, 2022
45bcf8a
Migrate namespaces
methylDragon May 18, 2022
49dd6ee
Add migration line
methylDragon May 18, 2022
f26ff80
Implement deprecation trick
methylDragon May 18, 2022
777b808
Add deprecation test
methylDragon May 18, 2022
7c7bcd3
Include config.hh
methylDragon May 18, 2022
53075a0
Use pragma deprecation message instead
methylDragon May 19, 2022
7c453fc
Ticktock config macros
methylDragon May 19, 2022
0fa97fc
Mention gz headers in migration and fix migration
methylDragon May 20, 2022
f250071
Migrate inline namespaces
methylDragon May 20, 2022
6c5da24
Migrate includes to gz
methylDragon May 20, 2022
8d05a87
Update config.hh
methylDragon May 20, 2022
56e69d2
Migrate Export.hh macros and deprecated test
methylDragon May 20, 2022
054f7d5
Migrate github links
methylDragon May 20, 2022
029072a
Migrate user-facing Ignition to Gazebo
methylDragon May 20, 2022
0ec2aa1
Migrate gz-common logging calls
methylDragon May 20, 2022
e55e7b6
Include config.hh in recursive directories and <lib>.hh
methylDragon May 22, 2022
8866f47
Include config.hh in .h and .hpp redirection headers
methylDragon May 22, 2022
009eea1
`Gazebo Robotics` -> `Gazebo`
methylDragon May 23, 2022
fb4dded
`ignitionrobotics` -> `gazebosim`
methylDragon May 23, 2022
5fa2355
Revert `gazebosim/gz-` to `ignitionrobotics/ign-` for `osrf-migration`
methylDragon May 24, 2022
90c3fe5
Tick-tock GZ_RENDERING_PLUGIN_PATH
methylDragon May 24, 2022
3efddda
Fix variables and add migration note
chapulina May 25, 2022
4f47b17
Tick-tock GZ_RENDERING_RESOURCE_PATH
methylDragon May 25, 2022
502bb26
Migrate Ignition's -> Gazebo's
methylDragon May 25, 2022
9ac449d
Wording changes
methylDragon May 25, 2022
a90546a
Migrate `igndbg` -> `gzdbg`
methylDragon May 25, 2022
a8c9b4c
Revert GZ_SIM_ env vars to IGNITION_GAZEBO_
methylDragon May 25, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
10 changes: 5 additions & 5 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ endif()
#--------------------------------------
# Find OGRE2: first try to find OGRE2 built with PlanarReflections support and
# fallback to look for OGRE2 without it. Both seems to works for ign-rendering.
# See https://github.com/ignitionrobotics/ign-rendering/issues/597
# See https://github.com/gazebosim/gz-rendering/issues/597
ign_find_package(IgnOGRE2 VERSION 2.2.0
COMPONENTS HlmsPbs HlmsUnlit Overlay PlanarReflections
PRIVATE_FOR ogre2
Expand All @@ -124,7 +124,7 @@ if (OGRE2_FOUND)
endif()

# Plugin install dirs
set(IGNITION_RENDERING_ENGINE_INSTALL_DIR
set(GZ_RENDERING_ENGINE_INSTALL_DIR
${CMAKE_INSTALL_PREFIX}/${IGN_LIB_INSTALL_DIR}/ign-${IGN_DESIGNATION}-${PROJECT_VERSION_MAJOR}/engine-plugins
)

Expand All @@ -149,12 +149,12 @@ endif()
#####################################
# Define compile-time default variables
if(MSVC)
set(IGN_RENDERING_PLUGIN_PATH ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_BINDIR})
set(GZ_RENDERING_PLUGIN_PATH ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_BINDIR})
else()
set(IGN_RENDERING_PLUGIN_PATH ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR})
set(GZ_RENDERING_PLUGIN_PATH ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR})
endif()

set(IGN_RENDERING_RESOURCE_PATH ${CMAKE_INSTALL_PREFIX}/${IGN_DATA_INSTALL_DIR})
set(GZ_RENDERING_RESOURCE_PATH ${CMAKE_INSTALL_PREFIX}/${IGN_DATA_INSTALL_DIR})

#============================================================================
# Configure the build
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1 +1 @@
See the [Ignition Robotics contributing guide](https://ignitionrobotics.org/docs/all/contributing).
See the [Gazebo contributing guide](https://gazebosim.org/docs/all/contributing).
662 changes: 331 additions & 331 deletions Changelog.md

Large diffs are not rendered by default.

26 changes: 15 additions & 11 deletions Migration.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,27 +5,31 @@ 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.

## Ignition Rendering 6.x to 7.x
## Gazebo Rendering 6.x to 7.x

### Deprecations

1. **ogre2/include/ignition/rendering/ogre2/Ogre2RenderEngine.hh**
+ Deprecated: `Ogre2GzHlmsSphericalClipMinDistance &HlmsCustomizations()`
+ Deprecated: `Ogre2IgnHlmsSphericalClipMinDistance &HlmsCustomizations()`
+ Replacement: `Ogre2GzHlmsSphericalClipMinDistance &SphericalClipMinDistance()`
2. The `ignition` namespace is deprecated and will be removed in future versions. Use `gz` instead.
3. Header files under `ignition/...` are deprecated and will be removed in future versions.
Use `gz/...` instead.
* The environment variable `IGN_RENDERING_PLUGIN_PATH` is deprecated. Use `GZ_RENDERING_PLUGIN_PATH` instead.

## Ignition Rendering 6.2.1 to 6.X
## Gazebo Rendering 6.2.1 to 6.X

### Modifications

1. Ogre 2 heightmaps: the Y position sign was flipped

1. `Scene::SetTime` is often unset. Ignition's `Ogre2` now defaults to 60hz otherwise rendering won't advance forward.
1. `Scene::SetTime` is often unset. Gazebo's `Ogre2` now defaults to 60hz otherwise rendering won't advance forward.
+ Mostly affects Particles.
+ Also may affect gaussian postprocessing and other filters dependant on time.
+ Previous behavior was using real time instead of simulation time, which is wrong.
+ See https://github.com/ignitionrobotics/ign-rendering/issues/556 for details.
+ See https://github.com/gazebosim/gz-rendering/issues/556 for details.

## Ignition Rendering 5.x to 6.x
## Gazebo Rendering 5.x to 6.x

### Modifications

Expand Down Expand Up @@ -60,33 +64,33 @@ release will remove the deprecated code.
1. **depth_camera_fs.glsl** and **depth_camera_final_fs.glsl**
+ Far clipping changed from clipping by depth to clipping by range, i.e. distance to point, so that the data generated will never exceed the specified max range of the camera.

## Ignition Rendering 4.0 to 4.1
## Gazebo Rendering 4.0 to 4.1

## ABI break

1. **ogre2/include/ignition/rendering/ogre2/Ogre2DepthCamera.hh**
+ Medium severity ABI break with the addition of the `AddRenderPass` override.

## Ignition Rendering 3.X to 4.X
## Gazebo Rendering 3.X to 4.X

### Deprecations

1. **ignition::common::Time** deprecated in favor of **std::chrono::steady_clock::duration**
1. **gz::common::Time** deprecated in favor of **std::chrono::steady_clock::duration**
+ Deprecated: `void BaseScene::SetSimTime(const common::Time &_time)`
+ Replacement: `void BaseScene::SetTime(const std::chrono::steady_clock::duration &_time)`
+ Deprecated: `common::Time SimTime() const`
+ Replacement: `std::chrono::steady_clock::duration Time() const`
+ Deprecated: `common::Time simTime`
+ Replacement: `std::chrono::steady_clock::duration time`

## Ignition Rendering 2.X to 3.X
## Gazebo Rendering 2.X to 3.X

### Deletions

1. **Ogre2DepthCamera.hh**
+ Removed unused member variables `captureData` and `newData`

## Ignition Rendering 1.X to 2.X
## Gazebo Rendering 1.X to 2.X

### Modifications

Expand Down
2 changes: 1 addition & 1 deletion NEWS
Original file line number Diff line number Diff line change
@@ -1 +1 @@
http://ignitionrobotics.org
http://gazebosim.org
24 changes: 12 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
# Ignition Rendering: Rendering library for robot applications
# Gazebo Rendering: Rendering library for robot applications

**Maintainer:** ichen [AT] openrobotics [DOT] org

[![GitHub open issues](https://img.shields.io/github/issues-raw/ignitionrobotics/ign-rendering.svg)](https://github.com/ignitionrobotics/ign-rendering/issues)
[![GitHub open pull requests](https://img.shields.io/github/issues-pr-raw/ignitionrobotics/ign-rendering.svg)](https://github.com/ignitionrobotics/ign-rendering/pulls)
[![GitHub open issues](https://img.shields.io/github/issues-raw/gazebosim/gz-rendering.svg)](https://github.com/gazebosim/gz-rendering/issues)
[![GitHub open pull requests](https://img.shields.io/github/issues-pr-raw/gazebosim/gz-rendering.svg)](https://github.com/gazebosim/gz-rendering/pulls)
[![Discourse topics](https://img.shields.io/discourse/https/community.gazebosim.org/topics.svg)](https://community.gazebosim.org)
[![Hex.pm](https://img.shields.io/hexpm/l/plug.svg)](https://www.apache.org/licenses/LICENSE-2.0)

Build | Status
-- | --
Test coverage | [![codecov](https://codecov.io/gh/ignitionrobotics/ign-rendering/branch/main/graph/badge.svg)](https://codecov.io/gh/ignitionrobotics/ign-rendering/branch/default)
Test coverage | [![codecov](https://codecov.io/gh/gazebosim/gz-rendering/branch/main/graph/badge.svg)](https://codecov.io/gh/gazebosim/gz-rendering/branch/default)
Ubuntu Focal | [![Build Status](https://build.osrfoundation.org/buildStatus/icon?job=ignition_rendering-ci-main-focal-amd64)](https://build.osrfoundation.org/job/ignition_rendering-ci-main-focal-amd64)
Homebrew | [![Build Status](https://build.osrfoundation.org/buildStatus/icon?job=ignition_rendering-ci-main-homebrew-amd64)](https://build.osrfoundation.org/job/ignition_rendering-ci-main-homebrew-amd64)
Windows | [![Build Status](https://build.osrfoundation.org/job/ign_rendering-ci-win/badge/icon)](https://build.osrfoundation.org/job/ign_rendering-ci-win/)

Ignition Rendering is a C++ library designed to provide an abstraction
Gazebo Rendering is a C++ library designed to provide an abstraction
for different rendering engines. It offers unified APIs for creating
3D graphics applications.

Ignition Rendering is a component in the ignition framework, a set
Gazebo Rendering is a component in the ignition framework, a set
of libraries designed to rapidly develop robot applications.

# Table of Contents
Expand Down Expand Up @@ -47,12 +47,12 @@ of libraries designed to rapidly develop robot applications.

# Install

See the [installation tutorial](https://ignitionrobotics.org/api/rendering/5.0/installation.html).
See the [installation tutorial](https://gazebosim.org/api/rendering/5.0/installation.html).

# Usage

The Ign Rendering API can be found in the documentation. See the
[installation tutorial](https://ignitionrobotics.org/api/rendering/5.0/installation.html)
[installation tutorial](https://gazebosim.org/api/rendering/5.0/installation.html)
on how to build the documentation files using Doxygen.

You can also take a look at the sample applications in the `examples` folder.
Expand Down Expand Up @@ -81,18 +81,18 @@ Rendering engine plugin implementation code is stored in their own folders
# Contributing

Please see
[CONTRIBUTING.md](https://ignitionrobotics.org/docs/all/contributing).
[CONTRIBUTING.md](https://gazebosim.org/docs/all/contributing).

# Code of Conduct

Please see
[CODE_OF_CONDUCT.md](https://github.com/ignitionrobotics/ign-gazebo/blob/main/CODE_OF_CONDUCT.md).
[CODE_OF_CONDUCT.md](https://github.com/gazebosim/gz-sim/blob/main/CODE_OF_CONDUCT.md).

# Versioning

This library uses [Semantic Versioning](https://semver.org/). Additionally, this library is part of the [Ignition Robotics project](https://ignitionrobotics.org) which periodically releases a versioned set of compatible and complimentary libraries. See the [Ignition Robotics website](https://ignitionrobotics.org) for version and release information.
This library uses [Semantic Versioning](https://semver.org/). Additionally, this library is part of the [Gazebo project](https://gazebosim.org) which periodically releases a versioned set of compatible and complimentary libraries. See the [Gazebo website](https://gazebosim.org) for version and release information.

# License

This library is licensed under [Apache 2.0](https://www.apache.org/licenses/LICENSE-2.0). See also the [LICENSE](https://github.com/ignitionrobotics/ign-rendering/blob/main/LICENSE) file.
This library is licensed under [Apache 2.0](https://www.apache.org/licenses/LICENSE-2.0). See also the [LICENSE](https://github.com/gazebosim/gz-rendering/blob/main/LICENSE) file.

4 changes: 2 additions & 2 deletions api.md.in
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
## Ignition @IGN_DESIGNATION_CAP@

Ignition @IGN_DESIGNATION_CAP@ is a component in Ignition Robotics, a set of libraries
designed to rapidly develop robot and simulation applications.
Ignition @IGN_DESIGNATION_CAP@ is a component in Gazebo, a set of libraries
designed to rapidly develop robot and simulation applications.

## License

Expand Down
14 changes: 7 additions & 7 deletions examples/actor_animation/GlutWindow.cc
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ void handleMouse()
g_rayQuery = rayCamera->Scene()->CreateRayQuery();
if (!g_rayQuery)
{
ignerr << "Failed to create Ray Query" << std::endl;
gzerr << "Failed to create Ray Query" << std::endl;
return;
}
}
Expand All @@ -171,7 +171,7 @@ void handleMouse()
2.0 * g_mouse.x / static_cast<double>(rayCamera->ImageWidth()) - 1.0;
double ny = 1.0 -
2.0 * g_mouse.y / static_cast<double>(rayCamera->ImageHeight());
g_rayQuery->SetFromCamera(rayCamera, ignition::math::Vector2d(nx, ny));
g_rayQuery->SetFromCamera(rayCamera, gz::math::Vector2d(nx, ny));
g_target = g_rayQuery->ClosestPoint();
if (!g_target)
{
Expand Down Expand Up @@ -201,7 +201,7 @@ void handleMouse()
if (g_mouse.motionDirty)
{
g_mouse.motionDirty = false;
auto drag = ignition::math::Vector2d(g_mouse.dragX, g_mouse.dragY);
auto drag = gz::math::Vector2d(g_mouse.dragX, g_mouse.dragY);

// left mouse button pan
if (g_mouse.button == GLUT_LEFT_BUTTON && g_mouse.state == GLUT_DOWN)
Expand Down Expand Up @@ -250,17 +250,17 @@ void updatePose(double _time)
for (auto &v : g_visuals)
{
//! [update pose]
std::map<std::string, ignition::math::Matrix4d> animFrames;
std::map<std::string, gz::math::Matrix4d> animFrames;
animFrames = g_skelAnim->PoseAt(_time, true);
std::map<std::string, ignition::math::Matrix4d> skinFrames;
std::map<std::string, gz::math::Matrix4d> skinFrames;
for (auto pair : animFrames)
{
std::string animNodeName = pair.first;
auto animTf = pair.second;

std::string skinName =
g_skel->NodeNameAnimToSkin(g_animIdx, animNodeName);
ignition::math::Matrix4d skinTf =
gz::math::Matrix4d skinTf =
g_skel->AlignTranslation(g_animIdx, animNodeName)
* animTf * g_skel->AlignRotation(g_animIdx, animNodeName);

Expand Down Expand Up @@ -542,7 +542,7 @@ void run(std::vector<ir::CameraPtr> _cameras,
{
if (_cameras.empty())
{
ignerr << "No cameras found. Scene will not be rendered" << std::endl;
gzerr << "No cameras found. Scene will not be rendered" << std::endl;
return;
}

Expand Down
4 changes: 2 additions & 2 deletions examples/actor_animation/GlutWindow.hh
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@
#include "gz/rendering/RenderTypes.hh"
#include "gz/common/graphics/Types.hh"

namespace ir = ignition::rendering;
namespace ic = ignition::common;
namespace ir = gz::rendering;
namespace ic = gz::common;

/// \brief Run the demo and render the scene from the cameras
/// \param[in] _cameras Cameras in the scene
Expand Down
14 changes: 7 additions & 7 deletions examples/actor_animation/Main.cc
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
#include "example_config.hh"
#include "GlutWindow.hh"

using namespace ignition;
using namespace gz;
using namespace rendering;

const std::string RESOURCE_PATH =
Expand All @@ -63,7 +63,7 @@ void buildScene(ScenePtr _scene, std::vector<VisualPtr> &_visuals,
// Skeleton will be animated by GlutWindow

//! [load mesh]
ignmsg << "Creating mesh with animations..." << std::endl;
gzmsg << "Creating mesh with animations..." << std::endl;
MeshDescriptor descriptor;
descriptor.meshName = common::joinPaths(RESOURCE_PATH, "walk.dae");
common::MeshManager *meshManager = common::MeshManager::Instance();
Expand All @@ -78,18 +78,18 @@ void buildScene(ScenePtr _scene, std::vector<VisualPtr> &_visuals,
_skel->AddBvhAnimation(bvhFile, scale);
if (_skel->AnimationCount() == 0)
{
ignerr << "Failed to load animation." << std::endl;
gzerr << "Failed to load animation." << std::endl;
return;
}
ignmsg << "Loaded animations: " << std::endl;
gzmsg << "Loaded animations: " << std::endl;
for (unsigned int i = 0; i < _skel->AnimationCount(); ++i)
ignmsg << " * " << _skel->Animation(i)->Name() << std::endl;
gzmsg << " * " << _skel->Animation(i)->Name() << std::endl;
//! [add animation]

unsigned int size = 25;
double halfSize = size * 0.5;
unsigned int count = 0;
ignmsg << "Creating " << size*size << " meshes with skeleton animation"
gzmsg << "Creating " << size*size << " meshes with skeleton animation"
<< std::endl;
for (unsigned int i = 0; i < size; ++i)
{
Expand Down Expand Up @@ -163,7 +163,7 @@ CameraPtr createCamera(const std::string &_engineName,
RenderEngine *engine = rendering::engine(_engineName, _params);
if (!engine)
{
ignwarn << "Engine '" << _engineName
gzwarn << "Engine '" << _engineName
<< "' is not supported" << std::endl;
return CameraPtr();
}
Expand Down
Loading