How can I detect elements of GUI using opencv? Given a screenshot of an application, is there any way of finding GUI elements of that application using only opencv? (something like in the image)


I tried to play with blending the image and other effects from the coherence.py sample in the opencv installation folder. Did not succeed to get a viable result. 

Has anyone did this? Do you have any idea what I might try? 

Thanks

(I'm new to opencv and image processing so please don't avoid obvious explanations if possible) :)
OpenCV's MSER extractor (documented here) might be helpful — the bounding box of local MSER groups would pretty closely match the green rectangles in your mockup.