Loading times Movies and failing to autodetect computer framerate

If this template helps then use it. If not then just delete and start from scratch.

OS
Windows 10
PsychoPy version
current stable - Standalone

What are you trying to achieve?:
Playing videos in a loop and getting system framerate

What did you try to make it work?:
Different file formats, different libraries for movies, deactivating any other processes

Problem description
What I am trying to achive is to play some very short movies (2-3s) in a loop (with some other stuff in between). It seems randomly these videos either take 3s until they are played or close to zero. Interestingly it does not change between videos but stays consistent throughtout the experiment. I recognized that psychopy seems to be unable to detect the framerates of my computer when the slow loading occurs. So I guess these two things are somehow connected. Any idea what might cause this?

Best regards
MrPi

It takes non-zero time to load a movie or image file from disk, which can easily exceed one screen refresh. This means that a movie can start later than intended and that there will be a pause in updating the screen while the loading occurs.

The solution to this is to pre-load the movie some time before when it actually needs to be displayed. That way it is cued up and will be ready to play immediately when scheduled.

To do this, make use of any time that occurs prior to the video onset when nothing is changing (e.g. a period with a fixation point or instruction text or similar). Insert a “Static period” component during that time. The static component doesn’t do anything: it just serves as an indicator of a period when the other stimuli are unchanging.

Now, in your video component you will see a new option next to the video file name field for when to update the video to be used. Instead of the current “every repeat”, you should now see a new option to load the file at a time which corresponds to the name of your new static period component.

Thanks Michael,
I already tried this. Same result sometimes close to zero loading times (in one experimental run)
sometimes 3s loading times (same videos different experimental run). So I would think it must be something else.