[vlc-devel] [PATCH 0/1] Fixed expansive loop when there is a clock gap

Jérémy VIGNELLES jeremy.vignelles at dev3i.fr
Thu Oct 12 16:38:01 CEST 2017


When trying to run that command line on windows:
./vlc -vv --sout="#cycle{dst=std{mux=ts,access=file,dst=/c/Users/JeremyVignelles/Desktop/rec/%Y%m%d%H%M%S.ts},duration=30s}" --sout-file-format --sout-ts-crypt-audio --sout-ts-crypt-video --sout-ts-csa-ck 0123456789ABCDEF rtsp://root:pass@10.10.210.101/mpeg4/media.amp

I had to wait a long time before anything is recorded.

The reason is that the offset of the cycles starts at 0 and increments slowly in the while loop, deleting and re creating the sout at each step.
Rather than looping a huge number of times, this can be done in a smart way, by skipping a round number of cycles before entering the loop, reducing dramatically the time when there is a clock gap.

with that patch, I obtained the following log line:

"cycle stream out debug: Clock gap of more that 18157 cycle detected, fast-forwarding cycles"



More information about the vlc-devel mailing list