Skip to content

Commit 03d2d01

Browse files
committed
getters of point cloud and global coordinate of lidar are implemented
1 parent f87009c commit 03d2d01

File tree

1 file changed

+25
-0
lines changed

1 file changed

+25
-0
lines changed

doc/3_sensor_models/3_2_lidar.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -478,4 +478,29 @@ Additionally, a function to draw the generated point cloud in the simulation is
478478

479479
for point in self.latest_point_cloud:
480480
point.draw(axes, elems)
481+
```
482+
483+
Finally, some getters for an external class are implemented as follow. The array of point cloud, global x-y coordinates of the LiDAR can be got.
484+
```python
485+
def get_point_cloud(self):
486+
"""
487+
Function to get latest point cloud data
488+
Each points are calculated on sensor coordinate system
489+
"""
490+
491+
return self.latest_point_cloud
492+
493+
def get_global_x_m(self):
494+
"""
495+
Function to get installation position x in global coordinate[m]
496+
"""
497+
498+
return self.params.get_global_x_m()
499+
500+
def get_global_y_m(self):
501+
"""
502+
Function to get installation position y in global coordinate[m]
503+
"""
504+
505+
return self.params.get_global_y_m()
481506
```

0 commit comments

Comments
 (0)