tsdemux failure with Audio and Video

Hello,

I am able to demux the video or audio from a transport stream file separately. However, when I try to demux both audio and video I get a no more pads error. Can someone explain why the pipeline fails? (I have noticed that the no more pads error also is output when giving the incorrect name of a pad.)

Here is the output of the failed pipe line:

gst-launch-1.0 -e -v qtmux name=“mux” ! filesink location=“uhd1280x720.mp4” filesrc location=uhd.trp ! tsdemux name=demux demux.
! queue ! h265parse ! omxh265dec ! nvvidconv ! ‘video/x-raw(memory:NVMM), width=(int)1280, height=(int)720, format=(string)I420’ ! omxh264enc profile=8 ! mux. demux
. ! queue ! aacparse ! mux. Setting pipeline to PAUSED …
Inside NvxLiteH264DecoderLowLatencyInitNvxLiteH264DecoderLowLatencyInit set DPB and MjstreamingInside NvxLiteH265DecoderLowLatencyInitNvxLiteH265DecoderLowLatencyIn
it set DPB and MjstreamingPipeline is PREROLLING …
WARNING: from element /GstPipeline:pipeline0/GstTSDemux:demux: Delayed linking failed.
Additional debug info:
./grammar.y(506): gst_parse_no_more_pads (): /GstPipeline:pipeline0/GstTSDemux:demux:
failed delayed linking some pad of GstTSDemux named demux to some pad of GstQueue named queue1

Here is the output of a working audio only pipeline

gst-launch-1.0 filesrc location=uhd.trp ! tsdemux ! queue ! aacparse ! filesink location=aac_audio.mp4 -e
Setting pipeline to PAUSED …
Pipeline is PREROLLING …
Pipeline is PREROLLED …
Setting pipeline to PLAYING …
New clock: GstSystemClock
Got EOS from element “pipeline0”.
Execution ended after 0:00:02.511629114
Setting pipeline to PAUSED …
Setting pipeline to READY …
Setting pipeline to NULL …
Freeing pipeline …

Hi RandDGraham,
Please refer to the following command and apply to your case:

gst-launch-1.0 qtmux name=m ! filesink location=test1.mp4 filesrc location=~/test.ts ! tsdemux name=dem dem. ! queue ! h264parse ! m. dem. ! queue ! avdec_aac ! audioconvert ! voaacenc ! m.

Not sure why but the aac stream needs to be decoded and re-encoded to make it work. It is potentially an issue in gstreamer element linkage.

Maybe other users can share experience to eliminate this dumb step.

(02/14/2017)UPDATE Not sure why but avdec_aac seems to be removed from gstreamer1.0-libav. Without avdec_aac, please run

gst-launch-1.0 qtmux name=m ! filesink location=test1.mp4 filesrc location=~/test.ts ! tsdemux name=dem dem. ! queue ! h264parse ! m. dem. ! queue ! aacparse ! faad ! audioresample ! audioconvert ! voaacenc ! m.

DaneLLL,

Thank you. After updating my pipeline, I am able to produce an output file with an audio as well as video track.

For the record my working pipeline was as follows.

gst-launch-1.0 -v -e qtmux name=m ! filesink location=uhd1280x720.mp4 filesrc location=uhd.trp ! tsdemux name=dem dem. ! queue ! h265parse ! omxh265dec ! nvvidconv ! ‘video/x-raw(memory:NVMM), width=(int)1280, height=(int)720, format=(string)I420’ ! omxh264enc profile=8 ! m. dem. ! queue ! avdec_aac ! audioconvert ! voaacenc ! m.

I am also facing a similar problem, and the same pad error:

my pipeline:
gst-launch-1.0 --gst-debug-level=3 mpegtsmux name=m ! filesink location=“test_streamer10.ts” dvbsrc modulation=“QAM 256” trans-mode=8k bandwidth=8 frequency=147000000 ! tsdemux name=dem dem. ! queue ! x264enc ! m. dem. ! queue ! avdec_aac ! audioconvert ! voaacenc ! m.

No output gets generated

New clock: GstSystemClock
0:00:01.003081113 28803 0x5628c8c79e30 WARN tsdemux tsdemux.c:1596:create_pad_for_stream: AC3 stream type found but no guaranteed way found to differentiate between AC3 and EAC3. Assuming plain AC3.
0:00:01.014280952 28803 0x5628c8c79e30 WARN default grammar.y:510:gst_parse_no_more_pads: warning: Delayed linking failed.
0:00:01.014333845 28803 0x5628c8c79e30 WARN default grammar.y:510:gst_parse_no_more_pads: warning: failed delayed linking some pad of GstTSDemux named dem to some pad of GstQueue named queue0
0:00:01.014468046 28803 0x5628c8c79e30 WARN default grammar.y:510:gst_parse_no_more_pads: warning: Delayed linking failed.
0:00:01.014499701 28803 0x5628c8c79e30 WARN default grammar.y:510:gst_parse_no_more_pads: warning: failed delayed linking some pad of GstTSDemux named dem to some pad of GstQueue named queue1
WARNING: from element /GstPipeline:pipeline0/GstTSDemux:dem: Delayed linking failed.
0:00:01.014813605 28803 0x5628c8c79e30 WARN tsdemux tsdemux.c:1596:create_pad_for_stream: AC3 stream type found but no guaranteed way found to differentiate between AC3 and EAC3. Assuming plain AC3.
Additional debug info:
./grammar.y(510): gst_parse_no_more_pads (): /GstPipeline:pipeline0/GstTSDemux:dem:
failed delayed linking some pad of GstTSDemux named dem to some pad of GstQueue named queue0