how to align the line detected to the middle of the image

1 回表示 (過去 30 日間)
PEIYU LIM
PEIYU LIM 2019 年 4 月 20 日
コメント済み: PEIYU LIM 2019 年 4 月 22 日
The two transmission line is detected and then how can I align that two blue lines to the middle of the image which are symmetrically

採用された回答

Image Analyst
Image Analyst 2019 年 4 月 20 日
Presumably you know the angle if the line(s) since you plotted them over the grayscale image. So use imrotate() to rotate it, then use imtranslate() to shift it.
  3 件のコメント
Image Analyst
Image Analyst 2019 年 4 月 21 日
Yes, though after it's been rotated, it might be a little tricky to figure out how much to translate it. I don't have any code for that, so give it a try and attach your script if you can't figure it out.
PEIYU LIM
PEIYU LIM 2019 年 4 月 22 日
Because I have a series of image which is slightly changed about the alignment.
So I'm finding the solution that can auto align the line to the middle and straight after the line has been detected.

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

その他の回答 (0 件)

Community Treasure Hunt

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

Start Hunting!

Translated by