<div dir="ltr"><div>Yeah, as far as I know, there really isn't a clean way to discard the first n seconds of a source via cli. The best I can think of is to use multifilesink, but that could be really awkward to get working.<br>
<br></div>I'm afraid you'll need to use python.<br><div><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, Jun 5, 2013 at 10:00 AM, a b <span dir="ltr"><<a href="mailto:genericgroupmail@gmail.com" target="_blank">genericgroupmail@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Thank you very much Angel,<br>
<br>
Really appreciate your input on this!<br>
<div class="HOEnZb"><div class="h5"><br>
On Wed, Jun 5, 2013 at 2:40 PM, Angel Martin <<a href="mailto:amartin@vicomtech.org">amartin@vicomtech.org</a>> wrote:<br>
> If you prefer the probe method this links could help you:<br>
> <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/manual/html/chapter-dataaccess.html" target="_blank">http://gstreamer.freedesktop.org/data/doc/gstreamer/head/manual/html/chapter-dataaccess.html</a><br>
> <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/manual/html/section-dynamic-pipelines.html" target="_blank">http://gstreamer.freedesktop.org/data/doc/gstreamer/head/manual/html/section-dynamic-pipelines.html</a><br>
><br>
> If you prefer a output-selector this one (ossbuild example):<br>
> <a href="http://code.google.com/p/ossbuild/source/browse/trunk/Main/GStreamer/Source/gst-plugins-bad/tests/icles/output-selector-test.c?r=926" target="_blank">http://code.google.com/p/ossbuild/source/browse/trunk/Main/GStreamer/Source/gst-plugins-bad/tests/icles/output-selector-test.c?r=926</a><br>
><br>
><br>
><br>
> 2013/6/5 a b <<a href="mailto:genericgroupmail@gmail.com">genericgroupmail@gmail.com</a>><br>
>><br>
>> Hi Angel,<br>
>><br>
>> Thanks for the quick reply!<br>
>> So sounds like these methods are for programming a solution.<br>
>> I had planned to look into the python pygst module in order to get<br>
>> away from relying on executing system calls to gst-launch. Maybe now<br>
>> is the time to do that.<br>
>><br>
>> Cheers!<br>
>><br>
>><br>
>> On Wed, Jun 5, 2013 at 12:52 PM, Angel Martin <<a href="mailto:amartin@vicomtech.org">amartin@vicomtech.org</a>><br>
>> wrote:<br>
>> > Hi,<br>
>> ><br>
>> > Check valve gst element or the probes to check the buffers timestamp to<br>
>> > drop<br>
>> > or pass the buffer.<br>
>> ><br>
>> > Best,<br>
>> ><br>
>> > Angel<br>
>> ><br>
>> > 2013/6/5 a b <<a href="mailto:genericgroupmail@gmail.com">genericgroupmail@gmail.com</a>><br>
>> >><br>
>> >> Hi all,<br>
>> >><br>
>> >> I have an issue with capturing a single snapshot from one particular<br>
>> >> device.<br>
>> >> Very often when starting to stream from one of our capture cards using<br>
>> >> the decklinksrc element the first few seconds of video are badly<br>
>> >> tuned/rendered before things finally correct themselves and the video<br>
>> >> appears normal.<br>
>> >> The way in which i am taking a screen shot means that the first video<br>
>> >> frame is output to an image file, which for this device means a very<br>
>> >> poor snapshot.<br>
>> >> There is no issue with the v4l2src capture cards as the first frame is<br>
>> >> always perfectly tuned/rendered.<br>
>> >><br>
>> >> Here is how i am doing it:<br>
>> >><br>
>> >> gst-launch decklinksrc mode=2 connection=4 ! ffmpegcolorspace !<br>
>> >> video/x-raw-rgb ! pngenc snapshot=true ! filesink location="frame.png"<br>
>> >><br>
>> >> Is there anyway or any element i can use to drop the first few seconds<br>
>> >> of video or the first e.g. 90 frames before taking the snapshot?<br>
>> >> I had read about the valve element and played with it but didn't see<br>
>> >> how it was going to work (for a start it causes execution to block).<br>
>> >> Ideally I'd like the command to run and finish with no further<br>
>> >> interaction as it does at the moment.<br>
>> >> If there is no real way to do it via a command line, then it would be<br>
>> >> useful if anyone could point to a way to do it programatically via<br>
>> >> python.<br>
>> >><br>
>> >> Thanks in advance.<br>
>> >> _______________________________________________<br>
>> >> gstreamer-devel mailing list<br>
>> >> <a href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a><br>
>> >> <a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
>> ><br>
>> ><br>
>> ><br>
>> > _______________________________________________<br>
>> > gstreamer-devel mailing list<br>
>> > <a href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a><br>
>> > <a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
>> ><br>
>> _______________________________________________<br>
>> gstreamer-devel mailing list<br>
>> <a href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a><br>
>> <a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
><br>
><br>
><br>
> _______________________________________________<br>
> gstreamer-devel mailing list<br>
> <a href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a><br>
> <a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
><br>
_______________________________________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br>Stirling Westrup<br>Programmer, Entrepreneur.<br><a href="https://www.linkedin.com/e/fpf/77228" target="_blank">https://www.linkedin.com/e/fpf/77228</a><br><a href="http://www.linkedin.com/in/swestrup" target="_blank">http://www.linkedin.com/in/swestrup</a><br>
<a href="http://technaut.livejournal.com" target="_blank">http://technaut.livejournal.com</a><br><a href="http://sourceforge.net/users/stirlingwestrup" target="_blank">http://sourceforge.net/users/stirlingwestrup</a>
</div>