I have a video and would like to be able to programmatically limit the section of the video which is displayed depending on whether/how a student has answered a question.
For instance, let’s say I have a 6 second clip but only want the student to be able to access the section from 1 to 4 seconds.
I would love to have sinks like
startTime: 1
endTime: 4
(Note that even if I used the existing time
sink that sets the initial time, but doesn’t stop the student from going to an earlier time.)
I can come close to simulating the desired behaviour with the following code
time: when this.time < 1 or this.time >= 4 1 otherwise this.time
But this produces a very jerky output, and in fact I was surprised that the code was even accepted because it paves the way for circular definitions.