0

i try to detect very clear edges in my image. i tried different solutions with opencv( houghlines, sobel, laplace ) . But with all this algorithm i dont get the result i want.

this is the image to detect the lines. the red lines are showing the edges i want to detect.

enter image description here

the image in the upper right corner is an video with the presenter the left side shows an presentation. There could be some edges as well. (e.g. when there is an picture with an frame in die presentation)

how would you do this edge detection? i do need the x coordinate of the vertical edge and the y coordinate of horizontal edge.

thanks for your help

Dharma
  • 3,007
  • 3
  • 23
  • 38
  • are the red lines present in the original image? if not, can you please add the original image? – Micka Apr 24 '15 at 10:19
  • source image: http://imgur.com/gspZR43 i blurred the personal information from the presenter. – Manul Hüttinger Apr 24 '15 at 10:26
  • Why exactly do you need to detect the edges? arent they constant? i.e. if you just hardcode the values that you need to crop out the video wouldn't that be enough? – mirosval Apr 24 '15 at 10:43
  • sadly the size of the speaker image can change from video to video. Sometimes it is 16:9 or 4:3 or the whole right side ( the speaker image and green area together can be the speaker image --> 9:16 ) – Manul Hüttinger Apr 24 '15 at 10:46
  • Try to convert the image to black and white image. And use findcontours – Gilad Apr 24 '15 at 12:07

1 Answers1

0

The lower right (green) square seems to be constant. You can, therefore, detect the connected component and get the top left pixel and you're done. Can that square have other things?

paghdv
  • 554
  • 1
  • 4
  • 14
  • what exactly do you mean with connected component? most of the time the square is an homogenous area. But sometimes there could be text inside this area ( e.g. agenda points of the presentaion) – Manul Hüttinger Apr 27 '15 at 07:46
  • It doesn't matter if it's not fully homogenious, the background (e.g. borders) have the same color. Check this connected components explanation. http://homepages.inf.ed.ac.uk/rbf/HIPR2/label.htm – paghdv Apr 27 '15 at 07:52
  • i didnt had time till now. hopefully in the next week. i did a fast workaround and give the function the coordinates i found out via gimp as a parameter. hopefully it will work in the future automatically – Manul Hüttinger May 31 '15 at 14:05