Search code examples
imagematlabopencvimage-processingtextures

Detecting texture in image


I have an aerial photo that contains trees and roofs of houses, and I need to detect only the trees. To do that I thought about using an algorithm that detect texture (maybe OpenCV or other) but I dont know how to implement it.

Image: enter image description here

OpenCV is the best in this case? Do you know another algorithm that do what I want? How can I implement it?


Solution

  • This is what Hue channel of the above image looks like : enter image description here

    Then you can threshold this image using a hard-coded value or you can use Otsu's method to find the threshold.

    To do all this use, you can use OpenCV APIs.