MATLAB: How to extract the frame around the windows

detectionedgesextractseparationwindow frame

Hello,
I need to extract the frame on the wall around the window. How can I do that? I have tried with edge detection and binarization, but I have got always a different result. There are images, where even the edges are not recognizable. But, there are images full with different edges where I can not eliminate the redundant components.
I hope someone can help me.
Thank you.

Best Answer

I suggest you just call rbbox(), imrect(), or imcrop() for the simplest solution. Anything else is not going to be "basic".
Related Question