[FFmpeg-user] update atomically
Anthony Griffiths
neuronetv at gmail.com
Wed Jan 28 10:20:32 CET 2015
I stream video with text overlay and wish to change the text every few
seconds, The text file I use is 'screentext.txt' and I update it by a
line in a bash script thus:
'cp -f new-screentext.txt screentext.txt'
However the ffmpeg stream process is crashing at random, blaming the
screentext.txt file for being empty or unfound. The ffmpeg docs say
the text file should be updated 'atomically'. What does that mean
exactly? I expect it means as fast as possible but I don't know how to
update the text file any faster. Is there some special way to update a
file atomically? This constant crashing is a headache and I need the
stream to be stable.
More information about the ffmpeg-user
mailing list