Auto cropping object in a image - iOS
Please help me to auto cropping objects in a image by finding its borders.
answered 2013-03-12 07:11:11 -0600
This post is a wiki. Anyone with karma >50 is welcome to improve it.
First of all, your question is fairly vague. There is almost no information contained to actually point out where our help can be located inside your own project. This makes it very difficult to answer specific.
Considering you have to find an object and an image, and crop that actual image there are several steps you should take:
Locate the actual object in the input image
This can be done in several ways and it depend on what information you have available.
--> Do you know the actual object beforehand? Do you have a 2D or 3D model defining it's borders? Do you have a sequence of images from the object?
--> Possibilities here are object recognition (template matching) or object detection (cascade detector, SVM detector, random forest detector, ...)
Give us some more input here please...
Define the objects boundaries
Depending on knowing the actual borders, once locating the bounding box, you could cut out the sample that you have retrieved. You could use a mask to define the actual borders and only segment that specified range of interest.
Resize the object
Basic cropping functionality is possible by downsampling and basic image operations. Go through the OpenCV docs for this problems. http://docs.opencv.org/modules/imgproc/doc/imgproc.html
Basically, if you do not provide us with more information, we cannot help you.
Asked: 2013-03-12 02:07:54 -0600
Seen: 1,319 times
Last updated: Mar 12 '13
Converting a Buffer to a Bitmap
Cant apply openCV framework to Xcode
Error in iOS framework and in tutorial
OpenCV 2.4.3 iOS CvVideoCamera throws build errors
Area of a single pixel object in OpenCV
build problems for android_binary_package - Eclipse Indigo, Ubuntu 12.04
OpenCV DescriptorMatcher matches