Sometimes CasparCG is slow playing a video

Hello,

I currently have around 1000 videoclips in my CasparCG library. I am working on a Visual Radio project and I already managed to have my songs sync with the videoclips using the SEEK command.

How this works: I have a radio automation system. It outputs the Now Playing info using POST to my PHP-script. It finds the needed info (clip name, the frame where SEEK has to start) from a MySQL database and then sends an AMCP command to CasparCG. It is nearly realtime and the HTTP server is not the culprit.

However, I recently started using 1080p video’s. These are around 100MB per file. I noticed the video’s that are for example 45MB (classics from around the years 2000) load much faster than recent clips with a size from around 120MB.

I see the HTTP server is sending the AMCP command in a timely fashion. But when the PLAY command was fired, it takes some more time to load the video, causing the video not to start immediately. Therefor, I noticed it is harder to keep the video’s in sync.

I am using CasparCG 2.3.1 server on Windows 10 with an NDI output. Any ideas how to reduce the delay on loading videoclips? The only thing that comes to mind is that the videoclips are on a network drive instead of a local one. But I have a very fast router with a fast internal network. Any other ideas?

If you can have the radio automation send you information on what’s cued or next up you could LOADBG the file.

What file format are you using? I’m guessing from the file sizes you mentioned that you are using MP4’s and to get to the correct frame it needs to find an earlier I-frame and decode from there until the frame you want. I’ve done these music automations before using ProRes files for the videos and no delays in seeking (since it’s an I-frame only codec).

I found out this problem only occures with some videoclips, not all of them. I have put of the problematic video’s in Adobe Media Encoder and tried again. It was smooth, fast and perfectly sync.

The clips have been rendered with ffmpeg, so I will try to re-render them with Media Encoder. I use Premiere Pro to find the correct frame number when the song starts. Now, that works perfectly. I don’t need to add or deduct any frames anymore.

Let’s see how this goes. Rerendering 969 clips now. :wink:

I have been at the hospital for a while and will need surgery in a few weeks. However, a short update. I converted everything to 25fps with Adobe Media Encoder and had no such problems ever since then. :slight_smile:

Hope everything will go well with your treatment.

Privacy Policy   Terms of Service