Suppose I have a directory, /tmp/media
, into which some video-producing device continually writes timestamped (in the filename) 60s MP4s, keeping an hour's worth of history, e.g.
(written at 13:42, deleted at 14:42) /tmp/media/video-2019-05-18T13:41:00.mp4
(13:43) /tmp/media/video-2019-05-18T13:42:00.mp4
(13:44) /tmp/media/video-2019-05-18T13:43:00.mp4
In other words, it's a continuous video stream from a camera broken up into 60s chunks.
Is there a way to "watch" this directory using gstreamer, decoding new files as they arrive?
My goal is to publish them to a Kinesis Video Stream using their GST plugin per the guide. For single files I believe I can use filesrc
, but I was wondering if there's a non-clunky way to keep pushing new files as they come into the directory to the stream.