How to detect corner in rectangle?

Hi, i'm new in matlab image processing. As we know, the rectangle has 4 corner A,B,C,D. How to detect every corner in rectangle automatically? it's like :
if (corner was in A) then
do..
end
if (corner was in B) then
do..
end
if (corner was in C) then
do..
end
if (corner was in D) then
do..
end
please help me..thank in advance
Best Regards,

Answers (1)

Image Analyst
Image Analyst on 6 Jan 2013
I don't know what you want to do. Did you use the corner() function in the Image Processing Toolbox to detect your corners? Okay, let's say you did. Then do you look at all the points that are returned and determine which is A, which is B, etc.? I assume you did. But I don't know what you want to do inside the if blocks.

6 Comments

actually, it's so hard to explain what i mean here. i've made some codes with two function. but it have to be attached, it's like an email. so, do you mind if i ask you more in your email? please help me.. thank in advance
Image Analyst
Image Analyst on 7 Jan 2013
Edited: Image Analyst on 7 Jan 2013
We don't do offline private consulting here. Here are options for uploading files: http://www.mathworks.com/matlabcentral/answers/7924-where-can-i-upload-images-and-files-for-use-on-matlab-answers
okay,let me ask about the corner. How about this error? i take it from http://www.mathworks.com/help/images/ref/corner.html
I = checkerboard(50,2,2);
C = corner(I);
imshow(I);
hold on
plot(C(:,1), C(:,2), 'r*');
??? Undefined function or method 'corner' for
input arguments of type 'double'.
Do "which corner" to see if you have it. It's fairly new, just introduced around a couple of years ago. You probably need to upgrade your version of MATLAB.
Alternately, Lily might not have the Image Processing toolbox installed or perhaps installed but not licensed. If she is using Student Version then she might not have gone back and installed it from her installation CD.
corner was introduced in R2010b. The release notes for that version say
In R2008b and later releases, you could find corners by computing a cornermetric matrix with the cornermetric function and then finding peak values. Now, you can simplify your workflow by using the corner function.

Sign in to comment.

Tags

Asked:

on 6 Jan 2013

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!