OpenCV

Started by
27 comments, last by sjhalayka 6 years, 4 months ago

I found out how to create the retina object using cv::bioinspired::Retina::create(), but now I get the following error:

fatal error C1189: #error: this is a private header which should not be used from outside of the OpenCV library

Advertisement

your including a header in your project that was only intended to be used within the opencv library. remove the line that includes that header in your project

It turns out that, yes, I had to comment out the #include "private.hpp" line in the precomp.h that came with the module code. So, basically, the opencv_contrib bioinspired module has a bug in it?

Has anyone used a Kinect sensor on their PC in OpenCV?

Rather than build OpenNI into OpenCV, I installed the Kinect SDK v2.0 onto a Windows 10 machine.

I'm still waiting for my $25 Xbox 360 Kinect, but here is some C++ code that I wrote in anticipation:

https://github.com/sjhalayka/kinect_opencv

And here's some C++ tutorials that I found:

https://homes.cs.washington.edu/~edzhang/tutorials/index.html

https://github.com/UnaNancyOwen/Kinect2Sample

I've used the kinect sensor for a few different things. If your trying to use it as a webcam though, i can tell you to not do that. You'll have to set variables in the system registry, install a few different things that seem to be basically hacked together, and then cross your fingers it works (as a webcam, to get the input stream). Then again that was a couple years ago since i've touched the kinect, so maybe its easier to use without the kinect sdk now. Microsoft discontinued the kinect anyway because it was more of a novelty, and honestly in my experience using a regular webcam can get you the same results, often times even better when you expect a lot of sunlight in the environment. The kinect is easy to use though, which is why it's probably appealing. i'd recommend don't go with the kinect. the intel realsense is pretty much just as good, smaller, and i believe is still not discontinued. The ir sensors (depth) work a couple feet further away on the kinect, otherwise the realsense is better in my opinion.

Thank you for your expertise.

A regular webcam doesn't come with a depth sensor and an infrared sensor. :)

Yep, we'll see if the code works right off the bat. Should have the Kinect soon.

the depth sensor is actually using the infrared sensor, which is why depth in these types of cameras don't work at all outside because of all the ir the sun is emitting. if you want good depth, i'd suggest buying a stereo camera, or making your own. The kinect is at least fun to play with though, all the hard work of detecting people is done for you

Hmm, I never thought about the sun drowning out the signal. See, I'm wondering if something like the Kinect is useful for obstacle detection, in the day time and night time. Perhaps a stereo camera is indeed best. Thanks!

Do you have code to calculate the depth map from the stereo disparity map? The book Learning OpenCV covers it in chapter 19, but I'm just not able to piece it all together.

i can totally help you with depth from a disparity image. i did a thing trying to get a job over at verizon: 

 

there's a link to the github for the code somewhere in the description. I only had a couple days to do this so it's not perfect, I wish i would have added in something like marching cubes to turn the point cloud into a mesh. maybe remove some of the noise as well from the point cloud

This topic is closed to new replies.

Advertisement