Queue prevents pipeline to preroll
Rodrigo Santos
rsantos at sequence.film
Mon Dec 19 13:17:49 UTC 2022
Hey Thibault,
Just tested and adding queues after the demuxer doesn't work either. For some reason, adding a queue after filesrc is preventing the pipeline to preroll, and the weird thing is that it only happens with some files.
In sum, this pipeline doesn't preroll:
gst-launch-1.0.exe filesrc location="$LOCATION" ! queue ! decodebin name=decoder ! queue ! audioresample ! audioconvert ! autoaudiosink decoder. ! queue ! autovideosink
and this one works perfectly:
gst-launch-1.0.exe filesrc location="$LOCATION" ! decodebin name=decoder ! queue ! audioresample ! audioconvert ! autoaudiosink decoder. ! queue ! autovideosink
This is the file I'm trying to play: https://drive.google.com/file/d/1y0u1eKbsKAavXpD6otWM0H1mMQQt9trO/view?usp=sharing
I'm using GStreamer 1.20.2.
Rodrigo Santos
---- On Thu, 15 Dec 2022 11:18:17 -0300 Thibault Saunier via gstreamer-devel <gstreamer-devel at lists.freedesktop.org> wrote ---
Hi Rodrigo,
It is a bit surprising the first pipeline works, the main issue you
have is that you should always use queues for each branch after
demuxers to avoid stalling the way you describe so the following
pipeline should work:
gst-launch-1.0.exe filesrc location="$LOCATION" ! queue ! decodebin
name=decoder ! queue ! audioresample ! audioconvert ! autoaudiosink
decoder. ! queue ! autovideosink
- Thibault
On Sun, 2022-12-11 at 17:32 -0300, Rodrigo Santos via gstreamer-devel
wrote:
> Just bumping this thread again as I've got no response. Does anyone
> have any idea why this is happening for this particular file (and
> others similar)?
>
> Rodrigo Santos
>
>
>
> ---- On Mon, 05 Dec 2022 12:16:42 -0300 Rodrigo Santos
> <mailto:rsantos at sequence.film> wrote ---
>
> > Hey folks,
> >
> > I have this pipeline that works without issues:
> >
> > gst-launch-1.0.exe filesrc location="$LOCATION" ! decodebin
> > name=decoder ! audioresample ! audioconvert ! autoaudiosink
> > decoder. ! autovideosink
> >
> > We are developing our own plugin with a custom buffering strategy.
> > To better understand how buffering works in pipelines I'm using a
> > queue after filesrc, the idea is to later add our custom element
> > before the queue. However, I noticed that for some files this
> > pipeline never prerolls:
> >
> > gst-launch-1.0.exe filesrc location="$LOCATION" ! queue ! decodebin
> > name=decoder ! audioresample ! audioconvert ! autoaudiosink
> > decoder. ! autovideosink
> >
> > PS: same behavior happens if I use queue2 or multiqueue. Here's the
> > output:
> >
> > gst-launch-1.0.exe filesrc location="$LOCATION" ! queue ! decodebin
> > name=decoder ! audioresample ! audioconvert ! autoaudiosink
> > decoder. ! autovideosink
> > Use Windows high-resolution clock, precision: 1 ms
> > Setting pipeline to PAUSED ...
> > Pipeline is PREROLLING ...
> > Got context from element 'autovideosink0':
> > gst.d3d11.device.handle=context,
> > device=(GstD3D11Device)"\(GstD3D11Device\)\ d3d11device2",
> > adapter=(uint)0, adapter-luid=(gint64)97066, device-id=(uint)39745,
> > vendor-id=(uint)32902, hardware=(boolean)true,
> > description=(string)"Intel\(R\)\ UHD\ Graphics";
> > Redistribute latency...
> > Redistribute latency...
> > Redistribute latency...0.0 %)
> > 0:00:00.0 / 0:01:56.1 (0.0 %)
> >
> > It shows the first video frame and gets stuck. The weird thing is
> > that if I link ONLY video or ONLY audio-related elements to the
> > decode bin the pipeline executes without problem. That is, the
> > following pipelines work:
> >
> > without video:
> > gst-launch-1.0.exe filesrc location="$LOCATION" ! queue !
> > decodebin name=decoder ! audioresample ! audioconvert !
> > autoaudiosink
> >
> > without audio:
> > gst-launch-1.0.exe filesrc location="$LOCATION" ! queue !
> > decodebin name=decoder ! autovideosink
> >
> > Could someone help me understand what is going on? It seems the
> > issue only happens with some files. The issue I just reported is
> > happening when $LOCATION is set to this
> > file: CRAZYCAR_HD_422_23p98_STEREO_MiniClip_20211021_2.mov - Google
> > Drive
> >
> > Rodrigo Santos
> >
> >
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20221219/8d89c73d/attachment.htm>
More information about the gstreamer-devel
mailing list