Snapnow is not working in compiled code

4 ビュー (過去 30 日間)
Vishal
Vishal 2017 年 9 月 3 日
編集済み: Vishal 2017 年 9 月 3 日
I have created a GUI in which need to capture the image and display it in the GUI. I need to display grid and grid axis around the image so was using snapnow to do it. The script runs without any errors in matlab, but when i compile it into a standalone application it is giving error on snapnow command.
I have compiled it as command line application and this is the error what i am getting:
Undefined function or variable 'snapnow'.
Error in CVC_b2>Btn_Captr_Img_Callback (line 278)
Error in gui_mainfcn (line 96)
Error in CVC_b2 (line 51)
Error in
@(hObject,eventdata)CVC_b2('Btn_Captr_Img_Callback',hObject,eventdata,guidata(hObject))
Error while evaluating uicontrol Callback
  1 件のコメント
Vishal
Vishal 2017 年 9 月 3 日
編集済み: Vishal 2017 年 9 月 3 日
Hey !!
Got the problem resolved by using
drawnow
instead of
snapnow
but i am still not sure why snapnow is not working as both are publishing the images. Can someone please help me understand what is the difference b/w the two commands and how come drawnow worked where snapnow threw error.

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

回答 (0 件)

カテゴリ

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

Community Treasure Hunt

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

Start Hunting!

Translated by