Intel RealSense and OpenCV3 [closed]

asked 2018-11-14 13:57:02 -0500

bquad gravatar image

Has anyone interfaced a realsense (D415) with OpenCV3 (3.4.3) on Ubuntu 16.04? I'm having a terrible time with it and wondering if I need to roll back to OpenCV2. If you have, could you give me some pointers. It doesn't seem to work like a typical USB webcam (which I have successfully integrated into my design of a lane detector) I just want to use 1 camera vice 2. Thanks

edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by bquad
close date 2018-11-15 12:02:12.294659

Comments

I have the realsense working through the realsense viewer. Just trying to import the feed just like any other camera/video.

bquad gravatar imagebquad ( 2018-11-14 14:01:52 -0500 )edit
1

USB cameras do not provide any unique capabilities using the generic webcam drivers. Have you tried using the Intel SDK for your system (Windows or Linux)? This seems to include an OS driver component as well as a user access library (librealsense2). I've used their SDK on Ubuntu on both ARM and X86-64. The instructions are straightforward. You could start here for Linux: https://github.com/IntelRealSense/lib... . There is related documentation throughout that github project.

opalmirror gravatar imageopalmirror ( 2018-11-14 14:07:28 -0500 )edit
1

Ah, well, then you can use librealsense2 API methods to import data. The library has several language bindings. There's a page about examples that interact with OpenCV here: https://github.com/IntelRealSense/lib...

opalmirror gravatar imageopalmirror ( 2018-11-14 14:16:58 -0500 )edit
1

I do know I'm using the intel-ros package from Intel and it's working with opencv 3.3.1 (packaged with ROS in its ros-kinetic-opencv3 package on Ubuntu 16.04) and 3.2 (as packaged in the opencv distribution packages on Ubuntu 18.04) with no problems.

opalmirror gravatar imageopalmirror ( 2018-11-14 14:19:49 -0500 )edit
1

It won't let me answer my own question until tomorrow. Thank you for the info, I will be using it with Kinetic as well so that's helpful. I forgot realsense requires USB3 for some features. OpenCV must be one of those features. It must have been a timeout issue. I swapped computers and the failing code works now. I will close this question out tomorrow.

bquad gravatar imagebquad ( 2018-11-14 15:12:41 -0500 )edit
1

Yes, you'll have enough forum points to answer your own question tomorrow. Kinetic works well; the ros-kinetic-opencv3 package will install all the development components you need. I've found USB3 requires short high-quality cables or there are dropouts in the data - and many cut rate so-called USB3 cables are not high quality or don't carry all the data lines. RealSense cameras use lots of power, make sure your host system meets specs.

opalmirror gravatar imageopalmirror ( 2018-11-14 15:40:07 -0500 )edit
1

Good advice. Thanks

bquad gravatar imagebquad ( 2018-11-15 12:00:19 -0500 )edit