jdibenes / hl2ss

HoloLens 2 Sensor Streaming. Real-time streaming of HoloLens 2 sensor data over WiFi. Research Mode and External USB-C A/V supported.
Other
203 stars 51 forks source link

Registering depth information into RGB image #80

Open JVal123 opened 8 months ago

JVal123 commented 8 months ago

Hello! I've recently updated the hl2ss version from 1.012.0 to 1.025.0.

Currently, I'm using the sample_integrator_pv.py script, which performs RGBD integration using Open3D. I've modified the script, simply to save both the rgb and depth images obtained by this script.

One problem arises, however. My objective is for the rgb images to have the depth information registered on them. This is already what happens in the old hl2ss version by default, but not on the new version. I simply get the rgb without any depth information. After comparing the two, I noticed that there is no depth registration being made onto the rgb image on the new version.

How can I obtain it in the new version?

jdibenes commented 8 months ago

Hello, The RGBD pair is given by the color and depth variables after line 140. Then, for example, you can insert code in line 141 to save both color and depth to files. Registration is done in lines 131-140.