I am trying to create an android app which can recognize Billiard balls on a pool table in an image coming from the camera. What would be the best approach to do this?
We can assume that the camera and the pool table are in fixed positions, but there could be object other than the balls on the pool table.
I am currently looking into two possible solutions:
Vuforia SDK - Simple API for object tracking / recognition, but I couldn't find any information about ball/sphere shape tracking. They have Cylinder and Image target that could possibly be used somehow to track the balls.
OpenCV - Seems much richer and steeper learning curve in comparison with Vuforia, but there is some information about Billiard ball detection online (e.g. this, and this).
Are there any addition approaches for solving this problem? What would be the easiest working approach for this?
Thanks!
The balls are moving or not?
I've used SURF (and SFIT) they work great for arrested objects. Have a look to the documentation page there are also two questions you should see this and this. Than if you want to calculate the trajectory I've tried Pymecavideo that uses OpenCv maybe a look into the source code could be interesting for your work.
Related
Im new in the Computer Vision field, so I'm learning from scratch how to generate point clouds from multiple image captures. I'm not implementing any of this on code yet, first I want to learn how this whole process should be done and then I'll code it.
So far I've learned about features detection algorithms , mostly SIFT and the remarkably more accurate A-KAZE, which detects much more features on each image and thus generates more dense clouds.
Then there comes the key matching algorithms, mainly Brute Force (BF) and FLANN.
Finally it should be a process in which you:
-first: get all the cameras orientation
-finally : generate the sparse point cloud.
But, until now , I've only found examples in OpenCV in which only two images are matched and their matched features are drawn. Im not able to find any example in which more images are matched and , more importantly, Im not able to find out how to find camera's orientation and to generate point clouds on OpenCV. Please, I need some help on those last stages. If you find any example of multiple image matching, point cloud generation it would be very helpfull . Thanks in advance!
OpenMvg has a nice structure-from-motion pipeline example to reconstruct 3D sparse point clouds from SIFT and AKAZE features. It even works without given any camera intrinsics (focal length, principal point).
I must create an Android app that recognizes some objects from the camera (car steering wheel, car wheel). I tried with Haar classifier but without success and I'm running out of time (it's a school project). So I decided to look for another way. I found some other methods for my goal - ORB. I found what should I do in this answer. My problem is that things are messed up in my head. Can you give me a step-by-step answer of what to do to implement the answer from the question in the link I gave:
From extracting the feature points to training the KD tree and using it for every frame from the camera.
Bonus questions:
Can you give a definition of feature point? It's something I couldn't exactly understand.
Will be the detecting slow using ORB? I know OpenCV can be used in native android, wouldn't that make the things faster?
I need to create this app as soon as possible. Please help!
I am currently developing a similar application. I would recommend getting something working with a single reference image first for a couple of reasons:
It's easier to do and understand if you're just starting out, and you can change it later.
For android applications you have limited processing capabilities so more images = lower fps.
You should have a look at the OpenCV tutorials which are quite helpful. Once you go through the “OpenCV for Android SDK” section and understand the three tutorials you can pretty easily add in functionality that will allow you to analyse the video feed.
The basic logic path I'd recommend following when making the app is:
Read in the reference image.
Create and use your FeatureDetector, DescriptorExtractor and DescriptorMatcher.
Use the above to detect keypoints and then descrive keypoints (the first two, don't forget to convert it to a mat and then to greyscale).
Every time you get a frame from your camera repeat step 3. on it and then compare the keypoints in the images (with the third part of 2.).
Use the result to determine if there is a match (if there is then draw a box around it or something).
Get a new frame.
Try making it to work for a single object and then add in others later. Another thing you could add is a screen at the start to allow users to pick what they want to search for.
Also ORB is reasonably fast, especially compared to SIFT and SURF. I get about 3fps on a HTC One with a single reference image.
I have a particular problem about image recognition on Android.
I am looking for some library able to recognize several objects from a photo. For instance, given a photo snapped by the user how can I count how many red circles and yellow triangles there are? Those shapes are just an example, since I want to recognize images which are pretty simple.
I have seen that there exists a good framework called Vuforia, which is designed for augmented reality. Do you think it is right for me? I am not an expert, so I ask you to help me.
check OpenCV for that, open source and works great on android
or
OpenCv
I'm looking for a 'basic' AR SDK that allows me to draw images and 3D shapes around the user (no matter where he is). It would be even better if the SDK includes a simple way to detect interaction with the shapes (something like onClick).
I made a project from scratch on Android but there's still a lot of work to do and I'll need to do the same on iOS after... So that's why I'm looking for an SDK or a similar project (no matter what platform).
I tested Metaio but it's quite expensive and maybe overkill for my purpose because it uses LLA coordinates.
I tested DroidAR on Android but it's only for Android and it looks heavy too (don't need the GPS).
How about Qualcomm's Vuforia? I was able to quickly get a sample project running on it.
EDIT Looks like I was wrong about what it could do. According to this (which is slightly dated, so who knows) Metaio might be your only choice.
i really don't sure what you really want to do ..but if you simply show images or 3d models on camera without any detection you can achieve this very easily i am explaining for Android and you can extend it to ios on same logic.
first approach:
you have to use custom camera of Android in your app,then use any game engine as per your need..i will suggest Jpct-ae or Rajawali
they are very simple to integrate and can be used for 2d images and 3d models.
this tutorial will explains a lot
keep the gl-surafce transparent and you can have model floating in space ...
second approach :
to add some more effect to your AR app you can use sensor values to move model in 3d space as per movement of device..it gives a cool effect.
use first approach and additionally collect sensor values and apply that matrix to gl camera of your game engine..for sensor values follow here
good tutorial here..
i hope this may help you..i done these a long time ago but try to help if you want..
I am developing a currency identification system for blind people. I need to check if the full currency note has been captured so I used square detection for that. It is currently working when the background is pure black or white, but not when the background is more advanced. What techniques can I use to solve this problem?
I am using OpenCV as my image processing framework. Can I use convolution? How?
need enhancement for square detection.
Result image of my code:
I am not sure whether rectangle detection is the best solution for what you want to do.
It will only work efficiently if the picture is taken right up from the money, and as you say will not be robust to cluttered backgrounds.
Is there a precise reason for not going to a direct pattern recognition system ?
I'd start with a picture of my currency and try to perform object recognition with it.
You will find loads of tutorials that can help you on the web, like for bottles or for bowls.
You might have a lot of possibilities, due to the number of currencies but you know it to be a finite number at least.