Hello Forum,
I have a process where (1) a small camera system generates H264 video segments ~ every 10 seconds, (2) a small application encodes the H264 into MP4, (3) the video segment file is transferred to a file server, and finally (4) the video clip is registered in a database. I need to write an application that will play the videos sequentially with no gap, loading and playing the new video clips as they arrive (well, getting the next clip from the database). So far I've tried the Playbin element where I set the url property to the next video clip when the _AboutToFinish event fires. However, there are some gap in the play back using this method. I've also tried to just pipe the output of files into a named pipe and then feed the Gtreamer pipeline from the fdsrc element, but this is is really brittle and gets stuck more often than I've been able to get it work. Does anyone know if an existing example of someone doing a similar application like this? From reading docs online, I think I *could* hook up the appsrc element to a method that preloads each video clip in memory, and then give chunks of the clip to the app's buffer request? But it's seems there should be an easier method ? Any advice is appreciated! It seems to me like I am making this harder than it needs to be. Thanks! |
On Mon, 2016-10-10 at 11:54 -0700, Piper984 wrote:
> Hello Forum, > > I have a process where (1) a small camera system generates H264 video > segments ~ every 10 seconds, (2) a small application encodes the H264 into > MP4, (3) the video segment file is transferred to a file server, and finally > (4) the video clip is registered in a database. > > I need to write an application that will play the videos sequentially with > no gap, loading and playing the new video clips as they arrive (well, > getting the next clip from the database). So far I've tried the Playbin > element where I set the url property to the next video clip when the > _AboutToFinish event fires. However, there are some gap in the play back > using this method. I've also tried to just pipe the output of files into a > named pipe and then feed the Gtreamer pipeline from the fdsrc element, but > this is is really brittle and gets stuck more often than I've been able to > get it work. > > Does anyone know if an existing example of someone doing a similar > application like this? From reading docs online, I think I *could* hook up > the appsrc element to a method that preloads each video clip in memory, and > then give chunks of the clip to the app's buffer request? But it's seems > there should be an easier method ? basically do exactly what you want. If you do the splitting yourself, you need to be very careful with how you generate the MP4 files to ensure that they can be played back gaplessly. It's probably better to use splitmuxsink for that directly. -- Sebastian Dröge, Centricular Ltd · http://www.centricular.com _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel signature.asc (985 bytes) Download Attachment |
Free forum by Nabble | Edit this page |