> Hi, i wish to find the distance from the webcam to different objects in
> an image. can this be done in some way?
> Joseph
>
One way is to use markers that your system would recognize or findalready marked objects (objects with visible distinctive and easy tofind features). You need to calibrate your camera first so as toincorporate all the distortions of the lens in your distancecalculation. Then you use FindExtrinsicCameraParams2 to find thelocation and orientation of your target. The target must consist ofat least 4 distinctive points of known relative location. This wouldbe the input of the function (the relative location of the 4 pointsand their location in the image). Not to mention that it also needsintrinsic_matrix, distortion_coeffs but these you will obtain duringcalibration.I have been using this method with a simple target of four squaresand it works nicely.
Have a look here: http://www.youtube.com/watch?v=4OK8ROW77pc
Message from OpenCV
Cy-Clops Project target to create "Vision of the Machine". Please share your experience on trying Cy-Clops. Are there any particular features you'd love to have? Tell us! By sharing your experience and helping us to improve the Cy-Clops.
4/16/2009
4/11/2009
Locate License Plate
[OpenCV] ANPR/Car number-plate recognition
You can use bottomhat transform to get rid of trouble in case of the same colorof car and plate. In addition, you can use radon transform to correct skewing. Itried so many methods to divide characters from the plate candidate region.First I extract the exact plate rectangle from the plate candidate region. ThenI apply global threshold and labeling to get characters as objects. I elect thenoncharacter object by some rules (area, width/length etc.). This method hassome trouble while the exact plate region is somehow connected to the otherregions. Does anyone have suggestion?
Alper
You can use bottomhat transform to get rid of trouble in case of the same colorof car and plate. In addition, you can use radon transform to correct skewing. Itried so many methods to divide characters from the plate candidate region.First I extract the exact plate rectangle from the plate candidate region. ThenI apply global threshold and labeling to get characters as objects. I elect thenoncharacter object by some rules (area, width/length etc.). This method hassome trouble while the exact plate region is somehow connected to the otherregions. Does anyone have suggestion?
Alper
License Plate Localization
License Plate Localization
You should look gabor filter. You have to find best filter parametersfor detection plate character, and than you can optain all platesafter filtering. Than you can use standart morp. operations on theimage.
https://commerce.metapress.com/content/0f1a8wk9mcru0djd/resource-secured/?target=fulltext.pdf&sid=sswqda45miyw0i55iwfxto45&sh=www.springerlink.com
You should look gabor filter. You have to find best filter parametersfor detection plate character, and than you can optain all platesafter filtering. Than you can use standart morp. operations on theimage.
https://commerce.metapress.com/content/0f1a8wk9mcru0djd/resource-secured/?target=fulltext.pdf&sid=sswqda45miyw0i55iwfxto45&sh=www.springerlink.com
License Plate Localization
[OpenCV] License Plate Localization
After detecting edges, you should apply morphological close operation. However,you should select kernel size considering the plate size. After that, you shouldapply connected component algorithm and filter very big and very small sizeobjects. Hence, the remaining objects are plate candidates which you can detectcharacters for each candidate.
Alper
After detecting edges, you should apply morphological close operation. However,you should select kernel size considering the plate size. After that, you shouldapply connected component algorithm and filter very big and very small sizeobjects. Hence, the remaining objects are plate candidates which you can detectcharacters for each candidate.
Alper
4/03/2009
Merging 2 Image
Hi,
a simple solution is:
You could initialize a new picture with the required dimensions, andcopy the data line for line, one after one from both pictures into thenew one.
Examplecode:
//Let's assume img1 and img2 are your 1024x768 grayscale-images of
// type IplImage
IplImage *combined = new IplImage;
CvSize size;
size.width=2048;
size.height=768;
combined = cvCreateImage(size, IPL_DEPTH_8U, 1);
for (int i = 0; i < (size.height-1); i++) { memcpy(&img3->imageData[i*img3->widthStep],&img1->imageData[i*img1->widthStep], img1->widthStep);
memcpy(&img3->imageData[i*img3->widthStep+img1->widthStep],&img2->imageData[i*img2->widthStep], img2->widthStep);
}
a simple solution is:
You could initialize a new picture with the required dimensions, andcopy the data line for line, one after one from both pictures into thenew one.
Examplecode:
//Let's assume img1 and img2 are your 1024x768 grayscale-images of
// type IplImage
IplImage *combined = new IplImage;
CvSize size;
size.width=2048;
size.height=768;
combined = cvCreateImage(size, IPL_DEPTH_8U, 1);
for (int i = 0; i < (size.height-1); i++) { memcpy(&img3->imageData[i*img3->widthStep],&img1->imageData[i*img1->widthStep], img1->widthStep);
memcpy(&img3->imageData[i*img3->widthStep+img1->widthStep],&img2->imageData[i*img2->widthStep], img2->widthStep);
}
Subscribe to:
Posts (Atom)