フィルターのクリア

Divide an image along lines and indexing different segments they produces

3 ビュー (過去 30 日間)
Tasneem Tabassum
Tasneem Tabassum 2017 年 3 月 30 日
コメント済み: Walter Roberson 2017 年 3 月 30 日
i wanted to plot axes at a specific points but couldn't. so added lines using hline and vline commands. now i have four segments at that point, but since they are not equal i can't use blockproc. but what need is i have got to index the four segments so that i can determine positions with respect to the intersecting points as quadrant position treating that point as origin.And I could also work with drawing normal axes, putting that point at origin and thus dividing the overall image into four indexed quadrants. Any of these two approach will do for me. but sadly i can't seem to do any. I'll be really grateful if anyone could help.Thanks.

回答 (1 件)

Walter Roberson
Walter Roberson 2017 年 3 月 30 日
Subtract the index of the origin point to come up with the mapped coordinates.
x_mapped = ColumnNumber - x_center;
y_mapped = RowNumber - y_center;
Note that x corresponds to columns (second coordinate), not to rows (first coordinates)
  2 件のコメント
Tasneem Tabassum
Tasneem Tabassum 2017 年 3 月 30 日
thanks :D ... but can you help me with after getting the mapped coordinates as origin how can i index the four axis quadrants!
Walter Roberson
Walter Roberson 2017 年 3 月 30 日
... You don't? You index in unmapped space.
Perhaps what you are looking for is something like:
YourMatrix(1:y_center, 1:x_center, :) %upper left
YourMatrix(y_center+1:end, 1:x_center, :) %lower left
and so on?

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

Community Treasure Hunt

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

Start Hunting!

Translated by