Is there any algorithm to find the locations of rectangles in an image?
古いコメントを表示
Hi
I have two images - on both the images i have some(same in both) nos of small rectangles.
I call one image to be base image and other to be row image(scanned).now i have the rectangles locations on the base image(used as a template) i want those rectangles locations on the row image (that is variable) means,
The row image might be skewed,waved or tiled. is there any algorithm available in MATLAB that can help me to find the rectangles on an image.
Please help me..
Thanking You
採用された回答
その他の回答 (1 件)
Sriram
2012 年 7 月 25 日
0 投票
Your question has to be in more clearer way! Up to my understanding - (Aim) You are trying to figure out the rectangles from a image - what you tried is using a template or pattern match with a known image!!. I don think so you need to go for correlation!
I would suggest you to use "regionprops" -which can measure the properties of image regions
2 件のコメント
meghna bhatt
2012 年 7 月 25 日
Sriram
2012 年 7 月 25 日
As you said regionprops doesn't gives the exact location. Using the below function after creating a template of the rectangular box, the position could be find !
normxcorr2 (template,original image)
the position of the rectangle which you required is found to be [34,31]
And are you going to use the same format/kind of OMR sheet ? If so check manually for the position in mm and based on the image size you can calibrate mm in pixels - allowing - automatically mark the position for different image provided the same format of OMR sheet is used! This would be the simplest way n will work better too !
カテゴリ
ヘルプ センター および File Exchange で Region and Image Properties についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!