Items with no label
3335 Discussions

How am I be able to capture the distance of a person being tracked in a video stream?

SWong19
Beginner
1,374 Views

Hi everyone, I want to know how can I utilise RealSense D435 to obtain the distance from a person front facing toward the camera in a video stream?

To be more specific, I wish to obtain and track their distance either based on their face or body skeleton. I'm currently using C# to develop this project.

I already have my code partially done but it's just basic that is to obtain the video stream but I have no idea how can I identify their distance from the camera and display it.

Thanks in advance.

0 Kudos
3 Replies
MartyG
Honored Contributor III
136 Views

If most of your code is done, you may be able to obtain the distance by converting the C language sample below to C# .

https://github.com/IntelRealSense/librealsense/tree/master/examples/C/distance librealsense/examples/C/distance at master · IntelRealSense/librealsense · GitHub

If more complex detection of people specifically is required, you may need to combine SDK 2.0 with a person tracking module in the OpenCV software platform.

0 Kudos
SWong19
Beginner
136 Views

Thank you very much. But sadly I have no fundamentals in C language so it will take some time for me to digest the code.

0 Kudos
MartyG
Honored Contributor III
136 Views

I located C# depth code examples in the .NET wrapper section of the SDK documentation.

https://github.com/IntelRealSense/librealsense/tree/master/wrappers/csharp librealsense/wrappers/csharp at master · IntelRealSense/librealsense · GitHub

0 Kudos
Reply