Find the edge of the screen and crop

1 次查看(过去 30 天)
lukbe
lukbe 2016-1-26
评论: lukbe 2016-1-26

Hello,I have this photo:

And I need to find a white marking in the corner, and crop photos. Is possible use this :

    I1 = imread('IMG_20160126_202236.jpg');
    I = rgb2gray(I1);
    C = corner(I,'Harris',50);

For find corner and I do not know how to cut it :(

Please can you help me to automatize this proces. Thank you

回答(1 个)

Image Analyst
Image Analyst 2016-1-26
If you're going to be needing to find monitors in all kinds of environments with weird angles and lighting and colors, then you might need to use something from the Computer Vision System Toolbox. I don't think the corner detector will work. Perhaps Dima (the developer of it) will answer.
Another option, if you don't have the CVST, is to use stdfilt() in the Image Processing Toolbox and find areas that are fairly uniform. Then threshold, fill holes, and get the convex hull.
  3 个评论
Image Analyst
Image Analyst 2016-1-26
Well we don't want to put a ton of effort in handling a crummy photo that you'll never end up having. There would have to be lots of code to handle pathological images that we wouldn't need if we had a decent picture. Post a good photo - one we can segment with little trouble.
lukbe
lukbe 2016-1-26
OK, I capture display with DSLR.

请先登录,再进行评论。

标签

Community Treasure Hunt

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

Start Hunting!

Translated by