RobotecAI / RobotecGPULidar

Other
217 stars 17 forks source link

IS_HIT; Rgl Lidar Publisher (Script) does not return non-hitted points. #338

Open luis-robotic opened 2 days ago

luis-robotic commented 2 days ago

Hello everyone.

I am working with the RGL LiDAR library in my project and I have observed that the pointcloud only returns the points that have collided with an object (i.e. when IS_HIT=1). But on the other hand, the points that do not collide (IS_HIT=0 ?) are not published. The pointcloud is then reduced to the points that give collision.

Isn't it possible to send the complete poincloud? So that the non-colliding points return an infinite range with which we can perform data processing?

Thank you in advance.

msz-rai commented 1 day ago

Hello @luis-robotic

Based on your previous activity in this repository, I assume your project uses RGLUnityPlugin from AWSIM. In this case, RglLidarPublisher connects RGL publishing nodes to LidarSensor via ConnectToLidarFrame() method. At this point, the point cloud is already compacted (does not contain non-hit points). The easiest way to omit compaction is to change the parent subgraph of the rglSubgraphToLidarFrame from rglSubgraphCompact to rglGraphLidar in this place. Note: This change will also affect other components that connect to the point cloud in the lidar frame using the mentioned method. If any problems occur, it may be necessary to redesign the RGL graph (and subgraphs).

I hope this will help with your issue.