Why is there difference between the data cursor value and array value

Hi,
I want to know why is there a difference between the cursor value obtained of an image and array value of a channel of an image.
Pls guide me.
Thanks

7 件のコメント

Ghulam
Ghulam 2019 年 10 月 15 日
arrayvaluech.png
Changing the x & y giving the same result
But why is it like this?
darova
darova 2019 年 10 月 15 日
Can you please attach entire script so i could analyze it?
Ghulam
Ghulam 2019 年 10 月 16 日
I = imread('2.jpg');
C = rgb2hsv(I);
C2 = C(:,:,2);
figure('Name','Channel 2');
imshow(C2)
Here it is.
darova
darova 2019 年 10 月 16 日
This result looks like exactly on your picture
BUt your picture is gray so actual (RGB) color of it is (0.7724 0.7724 0.7724)
arrayvaluech.png
Ghulam
Ghulam 2019 年 10 月 18 日
Thanks Darova for your reply,
Actually I wanted to know why is the x and y values differently represented in the picture as its opposite to the x,y values in the command line.
In pic x,y = 1120,840
While on command line x,y = 840,1120
This is what i wanted to know.
darova
darova 2019 年 10 月 18 日
Because position of your cursor is XY data but data of the image is (row,column)
X is column (changes in horizontal direction)
Y is row (changes in vertical direction)
Turlough Hughes
Turlough Hughes 2019 年 10 月 18 日
You should read the following documenation:
In particular, the first paragarph under the heading Intrinsic Coordinates refers to your question.

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

回答 (0 件)

質問済み:

2019 年 10 月 15 日

コメント済み:

2019 年 10 月 18 日

Community Treasure Hunt

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

Start Hunting!

Translated by