how to make variables inside a timer function global?

3 vues (au cours des 30 derniers jours)
debasish
debasish le 3 Juil 2012
Commenté : Diogo Milagres le 3 Fév 2017
hi.. i have used a timer that gets a frame from an axes(a webcam is live fed into the axes).
t=timer('TimerFcn',['frame=get(get(handles.cameraAxes,''children''),''cdata'');'.....getting
'stop(handles.video);','imshow(frame);'...dsf
],'StartDelay',5);
start(t);
How to use the variable 'frame' in another function??.I have tried to update the handles, but it doesn't work.
Kindly help.
  1 commentaire
Diogo Milagres
Diogo Milagres le 3 Fév 2017
Use global frame in all functions that need it.

Connectez-vous pour commenter.

Réponses (0)

Catégories

En savoir plus sur Environment and Settings dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by