Yes, would like to know in ffmpeg, under drawtext, the textfile (reload=1) is using read-write or read-only mode?
On Thu, 4 Nov 2021 at 00:50, Francois Visagie <francois.visa...@gmail.com> wrote: > > From: ffmpeg-user [mailto:ffmpeg-user-boun...@ffmpeg.org] On Behalf Of > > Adam Nielsen via ffmpeg-user > > Sent: 03 November 2021 15:10 > > To: LianCheng Tan > > Cc: Adam Nielsen; FFmpeg user questions > > Subject: Re: [FFmpeg-user] Alternative to Dynamic Text > > > > > I have tried to do what you have suggested. Somehow, it still cause > > > ffmpeg to crash at the exact moment the file is being renamed. > > > > > > By the way, I am running in Windows environment. Not sure, if in Linux > > > will this issue occurs. > > > > It works fine for me but I'm on Linux. > > > > If renaming doesn't work, have you tried copying the new file over the > top > of > > the old one? > > > > I'm not familiar enough with Windows to know how to atomically overwrite > a > > file. But I searched Google and found this: > > > > https://stackoverflow.com/questions/167414/is-an-atomic-file-rename- > > with-overwrite-possible-on-windows > > > > It suggests there is a Windows API function called MoveFileTransacted() > that > > you could use. > > > > I'm surprised just opening the file in read-write mode, seeking to the > start, > > then writing your content doesn't work though. You might get a frame > here > > or there with incomplete data but it won't cause ffmpeg to exit with an > error. > > Possibly the original poster is opening the file with read-write mode also > from within ffmpeg. > > That would be unnecessary, and could also explain "... ffmpeg unable to > read > the textfile when the other process is updating it." > > > > > Cheers, > > Adam. > > _______________________________________________ > > ffmpeg-user mailing list > > ffmpeg-user@ffmpeg.org > > https://ffmpeg.org/mailman/listinfo/ffmpeg-user > > > > To unsubscribe, visit link above, or email > ffmpeg-user-requ...@ffmpeg.org > > with subject "unsubscribe". > > _______________________________________________ > ffmpeg-user mailing list > ffmpeg-user@ffmpeg.org > https://ffmpeg.org/mailman/listinfo/ffmpeg-user > > To unsubscribe, visit link above, or email > ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe". > _______________________________________________ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".