Hey Elias,
Per your suggestion, I added a looping option to the movie stimulus. If the stimulus definition includes a “loop” parameter that evaluates to a non-zero value, then the movie will repeat indefinitely (until you stop it or set “loop” to zero). See this example.
While I was at it, I added another new parameter to movies: “ended”. If “ended” contains a variable name, the variable will be set to 1 after the last frame has displayed. (Specifically, it will be set to 1 at the time that the next frame would have been drawn, if there were one.) If you stop the movie before it finishes, or “loop” is non-zero, then the variable will not be set. See this example.
The last example also demonstrates an additional new feature: The expression parser now supports a new function, refreshRate()
, which returns the main display’s refresh rate in Hz. I added this because it’s useful in tests, but perhaps it’ll also be useful in real experiments.
All of these changes will be in tonight’s build, so please try them out when you can. If you have any problems, please let me know.
Chris