How can I read, in matlab, an image I have on my desktp with the imread () function?

1 回表示 (過去 30 日間)
matlab9000
matlab9000 2018 年 4 月 9 日
回答済み: Wick 2018 年 5 月 1 日
How can I read, in matlab, an image I have on my desktp with the imread () function?

回答 (1 件)

Wick
Wick 2018 年 5 月 1 日
You must put the name of the image in single quotes in the command. If the image is in a path beneath where MATLAB is currently executing, include the subfolders in the name. If it's somewhere else, use the entire path.
Assuming the file name is image_to_load.png then simply run:
img = imread('image_to_load.png');

カテゴリ

Help Center および File ExchangeGet Started with MATLAB についてさらに検索

製品

Community Treasure Hunt

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

Start Hunting!

Translated by