Widget to play and pause image stack display [message #80197] |
Thu, 10 May 2012 07:24 |
Helder Marchetto
Messages: 520 Registered: November 2011
|
Senior Member |
|
|
Hi,
I would like to have a base widget with a draw widget where I play a movie (as in displaying a series of images from a stack).
I would like to have the typical two buttons that start the play of the movie and the pause button.
I'm not that good with widgets, but I can't thick of how I would be able to interrupt a loop that displays the images.
I would have had something like:
PauseButtonPressed = 0
ImgNr = 0
LoopInterval = 0.2
WHILE ~PauseButtonPressed THEN
TV, Image[ImgNr,*,*]
ImgNr++
IF ImgNr GT nImages THEN ImgNr = 0
WAIT, LoopInterval
ENDWHILE
Is there a way to check if the user has clicked something in the loop?
Thanks,
Helder
|
|
|