フィルターのクリア

How can I use the image data stored in setappdata twice in my code?

2 ビュー (過去 30 日間)
Gee Cheng Mun
Gee Cheng Mun 2016 年 1 月 15 日
コメント済み: Gee Cheng Mun 2016 年 1 月 16 日
I stored an image data using setappdata in this function. I would like to use this image data twice in 2 separate functions. How can this be done?

採用された回答

Walter Roberson
Walter Roberson 2016 年 1 月 15 日
Either use nested functions and shared variables, or getappdata() in both functions where you need the data.
  3 件のコメント
Walter Roberson
Walter Roberson 2016 年 1 月 15 日
getappdata() does not display data; you need to imshow() or image() or imagesc() the retrieved data.
And of course the retrieval has to be after the data has been stored; in your second case your flow of routines might not have stored it yet.
Gee Cheng Mun
Gee Cheng Mun 2016 年 1 月 16 日
yes! I got it, thank you so much for all your help!:)

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeImages についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by