how to get a 3D view of grey image?

4 ビュー (過去 30 日間)
adi
adi 2020 年 6 月 15 日
コメント済み: Ameer Hamza 2020 年 6 月 15 日
Hi every one,
so i have a gray image and i want to have a view of the different regions in the image (steep/flat regions)
how can i display a 3D view so the x,y will represent the pixel location and z will represent the value of the pixel?
thank you!

採用された回答

Ameer Hamza
Ameer Hamza 2020 年 6 月 15 日
You can use surf()
img = im2double(imread('pears.png'));
img_gray = rgb2gray(img);
surf(img_gray)
shading interp
img_gray:
surf():
  2 件のコメント
adi
adi 2020 年 6 月 15 日
Thank you!
Ameer Hamza
Ameer Hamza 2020 年 6 月 15 日
I am glad to be of help!

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

その他の回答 (0 件)

Community Treasure Hunt

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

Start Hunting!

Translated by