Instant Replay with Gstreamer

Todd Agulnick todd at agulnick.com
Sun Dec 29 08:18:54 PST 2013


Pedro,

Thanks for making your code available -- it was really helpful. In
particular, reading your code I realized that I had very early on picked
the wrong flags when creating my blocking probe. Without your working code
to look at as an example (and compare, line by line, with mine) I don't
know that I ever would have detected my mistake.

I read your manifesto and what you're doing definitely shares some
similarities with my project. But yours is much more elaborate. In my case,
I start with a collection of raw, live HD video streams. I compress them so
I can keep a few minutes' worth in an in-memory ring buffer. Occasionally I
receive an external request to provide a short (< 30 second) clip of some
of the stored video as an MP4. The clip is short and the network is local,
so I don't need to stream.

I haven't seen the pipeline stalling problem that you have, but then again
I haven't run a pipeline for very long as I still don't have the basics
working yet. In your setup, when you close a file you immediately start
streaming into the next file, and it's my impression (possibly wrong) that
your code succeeds in finalizing the previous file properly because the
queue is still streaming (into the new file). In my case, when I finish
producing my clip, I block the queue again to wait for the next request and
as an apparent consequence, the previous file doesn't get finalized.

Separately, I don't know if you ever got answers to the questions you posed
in your linked document, but disk-life was definitely a concern that led to
my keeping everything in memory. The server that runs this stuff for us is
remote "in the field" so maximizing MTBF is a real concern.

-Todd





On Sun, Dec 29, 2013 at 7:56 AM, Pedro Côrte-Real <pedro at pedrocr.net> wrote:

> On Sun, Dec 29, 2013 at 6:58 AM, Todd Agulnick <todd at agulnick.com> wrote:
> > So I was happy to see the solution that you linked below that shows the
> code
> > simply setting the bin to GST_STATE_NULL to trigger the finalizing of the
> > file.
>
> Todd, that was my project Sebastian pointed to. I'm curious what you
> are doing as my project is a proof of concept of an surveilance camera
> server following this architecture:
>
> http://pedrocr.pt/text/a-better-base-for-opensource-iptv-tools/
>
> Maybe we're after something similar?
>
> I've basically implemented point 1 of that architecture last night,
> although I still need to debug why sometimes the pipeline will just
> stall with no error or output.
>
> Cheers,
>
> Pedro
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20131229/f11b714e/attachment.html>


More information about the gstreamer-devel mailing list