Skip to content

Commit 58a7cc4

Browse files
authored
Merge branch 'main' into matias-rayQueryFix
2 parents 7fdfee6 + b1d2ac8 commit 58a7cc4

File tree

95 files changed

+1206
-196
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

95 files changed

+1206
-196
lines changed

CMakeLists.txt

+10-19
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR)
33
#============================================================================
44
# Initialize the project
55
#============================================================================
6-
project(ignition-rendering6 VERSION 6.0.0)
6+
project(ignition-rendering7 VERSION 7.0.0)
77

88
#============================================================================
99
# Find ignition-cmake
@@ -15,7 +15,7 @@ set(IGN_CMAKE_VER ${ignition-cmake2_VERSION_MAJOR})
1515
#============================================================================
1616
# Set up the project
1717
#============================================================================
18-
ign_configure_project(VERSION_SUFFIX pre2)
18+
ign_configure_project(VERSION_SUFFIX pre1)
1919

2020
#============================================================================
2121
# Set project-specific options
@@ -62,30 +62,21 @@ endif()
6262

6363
#--------------------------------------
6464
# Find OGRE
65-
list(APPEND ign_ogre_components "RTShaderSystem" "Terrain" "Overlay")
65+
list(APPEND ign_ogre_components "RTShaderSystem" "Terrain" "Overlay" "Paging")
6666

67-
# Ogre versions greater than 1.9 are not officialy supported.
67+
ign_find_package(IgnOGRE VERSION 1.9.0
68+
COMPONENTS ${ign_ogre_components}
69+
REQUIRED_BY ogre
70+
PRIVATE_FOR ogre)
71+
72+
# Ogre versions greater than 1.9.x are not officialy supported.
6873
# Display a warning for the users on this setup unless they provide
6974
# USE_UNOFFICIAL_OGRE_VERSIONS flag
7075
if (NOT USE_UNOFFICIAL_OGRE_VERSIONS)
71-
# Only for checking the ogre version
72-
ign_find_package(IgnOGRE VERSION 1.10 QUIET)
73-
74-
if (OGRE_FOUND)
76+
if (${OGRE_VERSION} VERSION_GREATER_EQUAL 1.10.0)
7577
IGN_BUILD_WARNING("Ogre 1.x versions greater than 1.9 are not officially supported."
7678
"The software might compile and even work but support from upstream"
7779
"could be reduced to accepting patches for newer versions")
78-
ign_find_package(IgnOGRE VERSION 1.10
79-
COMPONENTS ${ign_ogre_components}
80-
REQUIRED_BY ogre
81-
PRIVATE_FOR ogre)
82-
else()
83-
# If ogre 1.10 or greater was not found, then proceed to look for 1.9.x
84-
# versions which are offically supported
85-
ign_find_package(IgnOGRE VERSION 1.9.0
86-
COMPONENTS ${ign_ogre_components}
87-
REQUIRED_BY ogre
88-
PRIVATE_FOR ogre)
8980
endif()
9081
endif()
9182

Changelog.md

+43-24
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,36 @@
11
## Ignition Rendering
22

3+
### Ignition Rendering 7.X
4+
5+
### Ignition Rendering 7.0.0 (202X-XX-XX)
6+
37
### Ignition Rendering 6.X
48

5-
### Ignition Rendering 6.0.0 (20XX-XX-XX)
9+
### Ignition Rendering 6.0.1 (2021-10-01)
10+
11+
1. Disable using selection buffer for ray queries
12+
* [Pull request #447](https://github.com/ignitionrobotics/ign-rendering/pull/447)
13+
14+
### Ignition Rendering 6.0.0 (2021-09-30)
15+
16+
1. Avoid configure warning when checking ogre-1.10
17+
* [Pull request #411](https://github.com/ignitionrobotics/ign-rendering/pull/411)
18+
* [Pull request #413](https://github.com/ignitionrobotics/ign-rendering/pull/413)
19+
20+
1. Use selection buffer in ray queries (ogre2)
21+
* [Pull request #378](https://github.com/ignitionrobotics/ign-rendering/pull/378)
22+
23+
1. Fix particle effect randomness
24+
* [Pull request #388](https://github.com/ignitionrobotics/ign-rendering/pull/388)
625

726
1. Update test config to run ogre 1.x tests in ign-rendering6 on macOS
827
* [Pull request #407](https://github.com/ignitionrobotics/ign-rendering/pull/407)
928
* [Pull request #409](https://github.com/ignitionrobotics/ign-rendering/pull/409)
10-
11-
1. Check if key exists in gpu lidar's user data
12-
* [Pull request #396](https://github.com/ignitionrobotics/ign-rendering/pull/396)
29+
* [Pull request #409](https://github.com/ignitionrobotics/ign-rendering/pull/409)
1330

1431
1. Clone visuals and geometries
1532
* [Pull request #397](https://github.com/ignitionrobotics/ign-rendering/pull/397)
33+
* [Pull request #434](https://github.com/ignitionrobotics/ign-rendering/pull/434)
1634

1735
1. Add SetSize API for LidarVisual and markers
1836
* [Pull request #392](https://github.com/ignitionrobotics/ign-rendering/pull/392)
@@ -23,36 +41,36 @@
2341

2442
1. Prevent default-constructed variants from holding a type
2543
* [Pull request #371](https://github.com/ignitionrobotics/ign-rendering/pull/371)
44+
* [Pull request #396](https://github.com/ignitionrobotics/ign-rendering/pull/396)
2645

2746
1. Temporarily set number of camera pass count per flush to 0 in ogre2 to prevent downstream build failures
2847
* [Pull request #367](https://github.com/ignitionrobotics/ign-rendering/pull/367)
2948

30-
1. Joint visual
31-
* [Pull request #366](https://github.com/ignitionrobotics/ign-rendering/pull/366)
32-
* [Pull request #387](https://github.com/ignitionrobotics/ign-rendering/pull/387)
49+
1. New visuals
50+
1. Joint visual
51+
* [Pull request #366](https://github.com/ignitionrobotics/ign-rendering/pull/366)
52+
* [Pull request #387](https://github.com/ignitionrobotics/ign-rendering/pull/387)
3353

34-
1. Fixing camera projection type test
35-
* [Pull request #361](https://github.com/ignitionrobotics/ign-rendering/pull/361)
54+
1. Center of mass visual
55+
* [Pull request #345](https://github.com/ignitionrobotics/ign-rendering/pull/345)
56+
57+
1. Inertia visual
58+
* [Pull request #326](https://github.com/ignitionrobotics/ign-rendering/pull/326)
3659

3760
1. UserData methods moved from Visual to Node
3861
* [Pull request #358](https://github.com/ignitionrobotics/ign-rendering/pull/358)
3962

4063
1. Replace renderOneFrame for per-workspace update calls
4164
* [Pull request #353](https://github.com/ignitionrobotics/ign-rendering/pull/353)
4265

43-
1. Center of mass visual
44-
* [Pull request #345](https://github.com/ignitionrobotics/ign-rendering/pull/345)
45-
4666
1. Segmentation Camera
4767
* [Pull request #329](https://github.com/ignitionrobotics/ign-rendering/pull/329)
4868
* [Pull request #419](https://github.com/ignitionrobotics/ign-rendering/pull/419)
69+
* [Pull request #443](https://github.com/ignitionrobotics/ign-rendering/pull/443)
4970

5071
1. Stub bounding box camera APIs
5172
* [Pull request #420](https://github.com/ignitionrobotics/ign-rendering/pull/420)
5273

53-
1. Inertia visual
54-
* [Pull request #326](https://github.com/ignitionrobotics/ign-rendering/pull/326)
55-
5674
1. Changed calculation for range clipping
5775
* [Pull request #325](https://github.com/ignitionrobotics/ign-rendering/pull/325)
5876

@@ -61,9 +79,7 @@
6179

6280
1. Add orthographic view controller
6381
* [Pull request #322](https://github.com/ignitionrobotics/ign-rendering/pull/322)
64-
65-
1. Port codecov to new configuration
66-
* [Pull request #318](https://github.com/ignitionrobotics/ign-rendering/pull/318)
82+
* [Pull request #361](https://github.com/ignitionrobotics/ign-rendering/pull/361)
6783

6884
1. Visualize wireframes
6985
* [Pull request #314](https://github.com/ignitionrobotics/ign-rendering/pull/314)
@@ -74,13 +90,16 @@
7490
1. From Ogre 2.1 to Ogre 2.2
7591
* [Pull request #272](https://github.com/ignitionrobotics/ign-rendering/pull/272)
7692
* [Pull request #393](https://github.com/ignitionrobotics/ign-rendering/pull/393)
93+
* [Pull request #436](https://github.com/ignitionrobotics/ign-rendering/pull/436)
94+
* [Pull request #426](https://github.com/ignitionrobotics/ign-rendering/pull/426)
95+
* [Pull request #440](https://github.com/ignitionrobotics/ign-rendering/pull/440)
7796

78-
1. All changes merged forward from ign-rendering5
79-
* [Pull request #310](https://github.com/ignitionrobotics/ign-rendering/pull/310)
80-
* [Pull request #331](https://github.com/ignitionrobotics/ign-rendering/pull/331)
81-
* [Pull request #350](https://github.com/ignitionrobotics/ign-rendering/pull/350)
82-
* [Pull request #401](https://github.com/ignitionrobotics/ign-rendering/pull/401)
83-
* [Pull request #406](https://github.com/ignitionrobotics/ign-rendering/pull/406)
97+
1. Documentation updates
98+
* [Pull request #425](https://github.com/ignitionrobotics/ign-rendering/pull/425)
99+
* [Pull request #431](https://github.com/ignitionrobotics/ign-rendering/pull/431)
100+
101+
1. Infrastructure
102+
* [Pull request #318](https://github.com/ignitionrobotics/ign-rendering/pull/318)
84103

85104
### Ignition Rendering 5.X
86105

examples/actor_animation/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR)
22
project(ignition-rendering-actor-animation)
3-
find_package(ignition-rendering6 REQUIRED)
3+
find_package(ignition-rendering7 REQUIRED)
44

55
include_directories(SYSTEM
66
${PROJECT_BINARY_DIR}

examples/camera_tracking/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR)
22
project(ignition-rendering-camera-tracking)
3-
find_package(ignition-rendering6 REQUIRED)
3+
find_package(ignition-rendering7 REQUIRED)
44

55
find_package(GLUT REQUIRED)
66
include_directories(SYSTEM ${GLUT_INCLUDE_DIRS})

examples/custom_scene_viewer/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR)
22
project(ignition-rendering-custom-scene-viewer)
3-
find_package(ignition-rendering6 REQUIRED)
3+
find_package(ignition-rendering7 REQUIRED)
44

55
include_directories(SYSTEM
66
${PROJECT_BINARY_DIR}

examples/custom_shaders/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ include_directories(SYSTEM
55
${PROJECT_BINARY_DIR}
66
)
77

8-
find_package(ignition-rendering6 REQUIRED)
8+
find_package(ignition-rendering7 REQUIRED)
99

1010
find_package(GLUT REQUIRED)
1111
include_directories(SYSTEM ${GLUT_INCLUDE_DIRS})

examples/custom_shaders_uniforms/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ include_directories(SYSTEM
55
${PROJECT_BINARY_DIR}
66
)
77

8-
find_package(ignition-rendering6)
8+
find_package(ignition-rendering7)
99

1010
set(TARGET_THIRD_PARTY_DEPENDS "")
1111

examples/gazebo_scene_viewer/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR)
22
project(ignition-rendering-gazebo-scene-viewer)
3-
find_package(ignition-rendering6 REQUIRED)
3+
find_package(ignition-rendering7 REQUIRED)
44
find_package(gazebo REQUIRED)
55

66
include_directories(SYSTEM ${GAZEBO_INCLUDE_DIRS})

examples/heightmap/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR)
22
project(ignition-rendering-heightmap)
3-
find_package(ignition-rendering6 REQUIRED)
3+
find_package(ignition-rendering7 REQUIRED)
44

55
include_directories(SYSTEM
66
${PROJECT_BINARY_DIR}

examples/hello_world_plugin/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 3.5 FATAL_ERROR)
33
set(IGN_PLUGIN_VER 1)
44
set(IGN_COMMON_VER 3)
55

6-
find_package(ignition-rendering6 REQUIRED)
6+
find_package(ignition-rendering7 REQUIRED)
77
find_package(ignition-plugin1 REQUIRED COMPONENTS all)
88

99
add_library(HelloWorldPlugin SHARED HelloWorldPlugin.cc)

examples/lidar_visual/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR)
22
project(ignition-rendering-lidar_visual)
3-
find_package(ignition-rendering6 REQUIRED)
3+
find_package(ignition-rendering7 REQUIRED)
44

55
include_directories(SYSTEM
66
${PROJECT_BINARY_DIR}

examples/mesh_viewer/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR)
22
project(ignition-rendering-mesh-viewer)
3-
find_package(ignition-rendering6 REQUIRED)
3+
find_package(ignition-rendering7 REQUIRED)
44

55
include_directories(SYSTEM
66
${PROJECT_BINARY_DIR}

examples/mouse_picking/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR)
22
project(ignition-rendering-mouse-picking)
3-
find_package(ignition-rendering6 REQUIRED)
3+
find_package(ignition-rendering7 REQUIRED)
44

55
include_directories(SYSTEM
66
${PROJECT_BINARY_DIR}

examples/ogre2_demo/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
cmake_minimum_required(VERSION 3.5 FATAL_ERROR)
22
project(ignition-rendering-ogre2-demo)
33

4-
find_package(ignition-rendering6)
4+
find_package(ignition-rendering7)
55

66
include_directories(SYSTEM
77
${PROJECT_BINARY_DIR}

examples/particles_demo/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR)
22
project(ignition-rendering-particles-demo)
3-
find_package(ignition-rendering6 REQUIRED)
3+
find_package(ignition-rendering7 REQUIRED)
44

55
include_directories(SYSTEM
66
${PROJECT_BINARY_DIR}

examples/particles_demo/Main.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,7 @@ int main(int _argc, char** _argv)
161161

162162
// Expose engine name to command line because we can't instantiate both
163163
// ogre and ogre2 at the same time
164-
std::string ogreEngineName("ogre");
164+
std::string ogreEngineName("ogre2");
165165
if (_argc > 1)
166166
{
167167
ogreEngineName = _argv[1];

examples/render_pass/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR)
22
project(ignition-rendering-render-pass)
33

4-
find_package(ignition-rendering6)
4+
find_package(ignition-rendering7)
55

66
find_package(GLUT REQUIRED)
77
include_directories(SYSTEM ${GLUT_INCLUDE_DIRS})

examples/segmentation_camera/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR)
22
project(ignition-rendering-segmentation-camera)
3-
find_package(ignition-rendering6 REQUIRED)
3+
find_package(ignition-rendering7 REQUIRED)
44

55
include_directories(SYSTEM
66
${PROJECT_BINARY_DIR}

examples/segmentation_camera/GlutWindow.cc

+35-16
Original file line numberDiff line numberDiff line change
@@ -136,8 +136,7 @@ void motionCB(int _x, int _y)
136136
void handleMouse()
137137
{
138138
std::lock_guard<std::mutex> lock(g_mouseMutex);
139-
// only ogre supports ray query for now so use
140-
// ogre camera located at camera index = 0.
139+
141140
ir::CameraPtr rayCamera = g_camera;
142141
if (!g_rayQuery)
143142
{
@@ -152,23 +151,44 @@ void handleMouse()
152151
if (g_mouse.buttonDirty)
153152
{
154153
g_mouse.buttonDirty = false;
154+
155+
// TODO: enable for segmentation cameras
156+
#if 0
157+
// test mouse picking
158+
if (g_mouse.button == GLUT_LEFT_BUTTON && g_mouse.state == GLUT_DOWN)
159+
{
160+
// Get visual using Selection Buffer from Camera
161+
ir::VisualPtr visual;
162+
ignition::math::Vector2i mousePos(g_mouse.x, g_mouse.y);
163+
visual = rayCamera->VisualAt(mousePos);
164+
if (visual)
165+
{
166+
std::cout << "Selected visual at position: ";
167+
std::cout << g_mouse.x << " " << g_mouse.y << ": ";
168+
std::cout << visual->Name() << "\n";
169+
}
170+
else
171+
{
172+
std::cout << "No visual found at position: ";
173+
std::cout << g_mouse.x << " " << g_mouse.y << std::endl;
174+
}
175+
}
176+
#endif
177+
178+
// camera orbit
155179
double nx =
156180
2.0 * g_mouse.x / static_cast<double>(rayCamera->ImageWidth()) - 1.0;
157181
double ny = 1.0 -
158182
2.0 * g_mouse.y / static_cast<double>(rayCamera->ImageHeight());
183+
g_rayQuery->SetFromCamera(rayCamera, ignition::math::Vector2d(nx, ny));
184+
g_target = g_rayQuery->ClosestPoint();
185+
if (!g_target)
186+
{
187+
// set point to be 10m away if no intersection found
188+
g_target.point = g_rayQuery->Origin() + g_rayQuery->Direction() * 10;
189+
return;
190+
}
159191

160-
// TODO(anyone) figure out why this code is causing a crash
161-
// g_rayQuery->SetFromCamera(rayCamera, ignition::math::Vector2d(nx, ny));
162-
// g_target = g_rayQuery->ClosestPoint();
163-
// if (!g_target)
164-
// {
165-
// // set point to be 10m away if no intersection found
166-
// g_target.point = g_rayQuery->Origin() + g_rayQuery->Direction() * 10;
167-
// return;
168-
// }
169-
170-
// TODO(anyone) get mouse wheel scroll zoom to work (currently isn't
171-
// working)
172192
// mouse wheel scroll zoom
173193
if ((g_mouse.button == 3 || g_mouse.button == 4) &&
174194
g_mouse.state == GLUT_UP)
@@ -203,8 +223,7 @@ void handleMouse()
203223
g_viewControl.SetTarget(g_target.point);
204224
g_viewControl.Orbit(drag);
205225
}
206-
// TODO(anyone) get right mouse button zoom to work. Seems to crash when
207-
// used with the RayQuery
226+
208227
// right mouse button zoom
209228
else if (g_mouse.button == GLUT_RIGHT_BUTTON && g_mouse.state == GLUT_DOWN)
210229
{

examples/simple_demo/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR)
22
project(ignition-rendering-simple-demo)
33

4-
find_package(ignition-rendering6)
4+
find_package(ignition-rendering7)
55

66
find_package(GLUT REQUIRED)
77
include_directories(SYSTEM ${GLUT_INCLUDE_DIRS})

0 commit comments

Comments
 (0)