How do i isolate the vertical lines in an image?

1 回表示 (過去 30 日間)
N/A
N/A 2018 年 3 月 7 日
コメント済み: N/A 2018 年 4 月 25 日
Good day, I am trying to isolate the vertical lines in an image to make the image show only the vertical lines present in the image.
  1 件のコメント
N/A
N/A 2018 年 4 月 25 日
I am fairly new to MATLAB.

サインインしてコメントする。

回答 (1 件)

Arun Mathamkode
Arun Mathamkode 2018 年 3 月 20 日
You can use the imgradientxy function to find gradients along x and y axis. Since the vertical lines will have gradients along x direction, you can threshold the gradients along x direction to separate the vertical lines. For example, if I is the image
[gx gy]=imgradientxy(I);
VertLines=gx>950 % Choose a proper threshod
figure, imshow(VertLines,[]);

Community Treasure Hunt

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

Start Hunting!

Translated by