How to drop first X frames or first X seconds of video

a b genericgroupmail at gmail.com
Wed Jun 5 05:48:45 PDT 2013


Hi Angel,

Thanks for the quick reply!
So sounds like these methods are for programming a solution.
I had planned to look into the python pygst module in order to get
away from relying on executing system calls to gst-launch. Maybe now
is the time to do that.

Cheers!


On Wed, Jun 5, 2013 at 12:52 PM, Angel Martin <amartin at vicomtech.org> wrote:
> Hi,
>
> Check valve gst element or the probes to check the buffers timestamp to drop
> or pass the buffer.
>
> Best,
>
> Angel
>
> 2013/6/5 a b <genericgroupmail at gmail.com>
>>
>> Hi all,
>>
>> I have an issue with capturing a single snapshot from one particular
>> device.
>> Very often when starting to stream from one of our capture cards using
>> the decklinksrc element the first few seconds of video are badly
>> tuned/rendered before things finally correct themselves and the video
>> appears normal.
>> The way in which i am taking a screen shot means that the first video
>> frame is output to an image file, which for this device means a very
>> poor snapshot.
>> There is no issue with the v4l2src capture cards as the first frame is
>> always perfectly tuned/rendered.
>>
>> Here is how i am doing it:
>>
>> gst-launch decklinksrc mode=2 connection=4 ! ffmpegcolorspace !
>> video/x-raw-rgb ! pngenc snapshot=true ! filesink location="frame.png"
>>
>> Is there anyway or any element i can use to drop the first few seconds
>> of video or the first e.g. 90 frames before taking the snapshot?
>> I had read about the valve element and played with it but didn't see
>> how it was going to work (for a start it causes execution to block).
>> Ideally I'd like the command to run and finish with no further
>> interaction as it does at the moment.
>> If there is no real way to do it via a command line, then it would be
>> useful if anyone could point to a way to do it programatically via
>> python.
>>
>> Thanks in advance.
>> _______________________________________________
>> gstreamer-devel mailing list
>> gstreamer-devel at lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
>
>
>
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
>


More information about the gstreamer-devel mailing list