Skip to content

Commit 0367f5d

Browse files
authored
6 ➡️ 7 (main) (#172)
Signed-off-by: Ian Chen <ichen@osrfoundation.org> Signed-off-by: Louise Poubel <louise@openrobotics.org>
2 parents 7ec85fb + 548e38b commit 0367f5d

File tree

5 files changed

+105
-3
lines changed

5 files changed

+105
-3
lines changed

Changelog.md

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,28 @@
1-
## Ignition Sensors 6
1+
## Ignition Sensors 7
22

33
### Ignition Sensors 7.X.X
44

55
### Ignition Sensors 7.0.0 (202X-XX-XX)
66

7+
## Ignition Sensors 6
8+
79
### Ignition Sensors 6.X.X
810

9-
### Ignition Sensors 6.0.0 (2021-09-22)
11+
### Ignition Sensors 6.0.1 (2021-11-12)
12+
13+
1. Disable GPU lidar tests on macOS
14+
* [Pull request #163](https://github.com/ignitionrobotics/ign-sensors/pull/163)
15+
16+
1. Added macOS install instructions.
17+
* [Pull request #162](https://github.com/ignitionrobotics/ign-sensors/pull/162)
18+
19+
1. Destroy rendering sensors when sensor is removed.
20+
* [Pull request #169](https://github.com/ignitionrobotics/ign-sensors/pull/169)
21+
22+
### Ignition Sensors 6.0.0 (2021-09-30)
23+
24+
1. Trivial tutorial typo correction in Custom Sensors tutorial
25+
* [Pull request #160](https://github.com/ignitionrobotics/ign-sensors/pull/160)
1026

1127
1. Bumps in fortress: ign-sensors6
1228
* [Pull request #120](https://github.com/ignitionrobotics/ign-sensors/pull/120)

src/RenderingSensor.cc

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,15 @@ RenderingSensor::RenderingSensor() :
5656
//////////////////////////////////////////////////
5757
RenderingSensor::~RenderingSensor()
5858
{
59+
if (!this->dataPtr->scene)
60+
return;
61+
for (auto &s : this->dataPtr->sensors)
62+
{
63+
auto sensor = s.lock();
64+
if (sensor)
65+
this->dataPtr->scene->DestroySensor(sensor);
66+
}
67+
this->dataPtr->sensors.clear();
5968
}
6069

6170
/////////////////////////////////////////////////

test/integration/camera.cc

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,18 @@ void CameraSensorTest::ImagesWithBuiltinSDF(const std::string &_renderEngine)
109109

110110
EXPECT_TRUE(helper.WaitForMessage()) << helper;
111111

112+
// test removing sensor
113+
// first make sure the sensor objects do exist
114+
auto sensorId = sensor->Id();
115+
auto cameraId = sensor->RenderingCamera()->Id();
116+
EXPECT_EQ(sensor, mgr.Sensor(sensorId));
117+
EXPECT_EQ(sensor->RenderingCamera(), scene->SensorById(cameraId));
118+
// remove and check sensor objects no longer exist in both sensors and
119+
// rendering
120+
EXPECT_TRUE(mgr.Remove(sensorId));
121+
EXPECT_EQ(nullptr, mgr.Sensor(sensorId));
122+
EXPECT_EQ(nullptr, scene->SensorById(cameraId));
123+
112124
// Clean up
113125
engine->DestroyScene(scene);
114126
ignition::rendering::unloadEngine(engine->Name());

test/integration/gpu_lidar_sensor.cc

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -901,31 +901,51 @@ void GpuLidarSensorTest::Topic(const std::string &_renderEngine)
901901
}
902902

903903
/////////////////////////////////////////////////
904+
#ifdef __APPLE__
905+
TEST_P(GpuLidarSensorTest, DISABLED_CreateGpuLidar)
906+
#else
904907
TEST_P(GpuLidarSensorTest, CreateGpuLidar)
908+
#endif
905909
{
906910
CreateGpuLidar(GetParam());
907911
}
908912

909913
/////////////////////////////////////////////////
914+
#ifdef __APPLE__
915+
TEST_P(GpuLidarSensorTest, DISABLED_DetectBox)
916+
#else
910917
TEST_P(GpuLidarSensorTest, DetectBox)
918+
#endif
911919
{
912920
DetectBox(GetParam());
913921
}
914922

915923
/////////////////////////////////////////////////
924+
#ifdef __APPLE__
925+
TEST_P(GpuLidarSensorTest, DISABLED_TestThreeBoxes)
926+
#else
916927
TEST_P(GpuLidarSensorTest, TestThreeBoxes)
928+
#endif
917929
{
918930
TestThreeBoxes(GetParam());
919931
}
920932

921933
/////////////////////////////////////////////////
934+
#ifdef __APPLE__
935+
TEST_P(GpuLidarSensorTest, DISABLED_VerticalLidar)
936+
#else
922937
TEST_P(GpuLidarSensorTest, VerticalLidar)
938+
#endif
923939
{
924940
VerticalLidar(GetParam());
925941
}
926942

927943
/////////////////////////////////////////////////
944+
#ifdef __APPLE__
945+
TEST_P(GpuLidarSensorTest, DISABLED_ManualUpdate)
946+
#else
928947
TEST_P(GpuLidarSensorTest, ManualUpdate)
948+
#endif
929949
{
930950
ManualUpdate(GetParam());
931951
}

tutorials/install.md

Lines changed: 46 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,22 @@ sudo apt-get update
2323
sudo apt install libignition-sensors<#>-dev
2424
```
2525

26+
### macOS
27+
28+
On macOS, add OSRF packages:
29+
```
30+
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
31+
brew tap osrf/simulation
32+
```
33+
34+
Install Ignition Sensors:
35+
```
36+
brew install ignition-sensors<#>
37+
```
38+
39+
Be sure to replace `<#>` with a number value, such as 5 or 6, depending on
40+
which version you need.
41+
2642
### Windows
2743

2844
Binary install is pending `ignition-rendering` and `ignition-sensors` being added to conda-forge.
@@ -72,6 +88,36 @@ Ignition Sensors requires:
7288
sudo make install
7389
```
7490

91+
### macOS
92+
93+
1. Clone the repository
94+
```
95+
git clone https://github.com/ignitionrobotics/ign-sensors -b ign-sensors<#>
96+
```
97+
Be sure to replace `<#>` with a number value, such as 5 or 6, depending on
98+
which version you need.
99+
100+
2. Install dependencies
101+
```
102+
brew install --only-dependencies ignition-sensors<#>
103+
```
104+
Be sure to replace `<#>` with a number value, such as 5 or 6, depending on
105+
which version you need.
106+
107+
3. Configure and build
108+
```
109+
cd ign-sensors
110+
mkdir build
111+
cd build
112+
cmake ..
113+
make
114+
```
115+
116+
4. Optionally, install
117+
```
118+
sudo make install
119+
```
120+
75121
### Windows
76122

77123
#### Install Prerequisites
@@ -165,4 +211,3 @@ Follow these steps to run tests and static code analysis in your clone of this r
165211
```
166212
make codecheck
167213
```
168-

0 commit comments

Comments
 (0)