GNOME Bugzilla – Bug 761419
avi file decoding problem
Last modified: 2016-05-22 19:34:35 UTC
Hi I tyried below avi file deoding and found the problem Please check and let me know the solutions. #gst-launch-1.0 filesrc location=04317.avi ! decodebin name="decode" decode. ! videoconvert ! videoscale ! x264enc ! queue ! mp4mux name="mux" ! filesink location="result.mp4" --gst-debug-level=3 Setting pipeline to PAUSED ... 0:00:00.032638536 29591 0x1538d60 WARN basesrc gstbasesrc.c:3481:gst_base_src_start_complete:<filesrc0> pad not activated yet Pipeline is PREROLLING ... 0:00:00.038679364 29591 0x152b680 WARN riff riff-media.c:929:gst_riff_create_video_caps: Unknown video fourcc YVU9 Redistribute latency... 0:00:00.047070499 29591 0x7fdae4004b20 ERROR libav :0:: Context scratch buffers could not be allocated due to unknown size. Redistribute latency... 0:00:00.317928185 29591 0x152b590 FIXME basesink gstbasesink.c:3125:gst_base_sink_default_event:<filesink0> stream-start event without group-id. Consider implementing group-id handling in the upstream elements Pipeline is PREROLLED ... Setting pipeline to PLAYING ... New clock: GstSystemClock <= not finished and stopped execution. ^CCaught interrupt -- handling interrupt. Interrupt: Stopping pipeline ... (gst-launch-1.0:29591): GLib-CRITICAL **: Source ID 47 was not found when attempting to remove it Execution ended after 14518229136 ns. Setting pipeline to PAUSED ... Setting pipeline to READY ... Setting pipeline to NULL ... Freeing pipeline ... (gst-launch-1.0:29387): GLib-CRITICAL **: Source ID 57 was not found when attempting to remove it Execution ended after 18270412350 ns. Setting pipeline to PAUSED ... Setting pipeline to READY ... Setting pipeline to NULL ... Freeing pipeline ... # gst-typefind-1.0 04317.avi 04317.avi - video/x-msvideo you can download file https://www.dropbox.com/s/tg6cy1er7iaagnf/031002134b0e73685d73db95032c3d33124_yds04317.avi?dl=0
Could you try playing the file first? Does gst-play-1.0 foo.avi work? If not, what is the output?
For playback on latest master gst-play-1.0 file & gst-launch-1.0 filesrc ! decodebin ... as well as a manual pipeline[1] all work here. Given sample launch line also works (as in: it produces a playable file). [1] gst-launch-1.0 filesrc location=031002134b0e73685d73db95032c3d33124_yds04317.avi ! avidemux name=demux demux. ! queue ! mpeg4videoparse ! avdec_mpeg4 ! videoconvert ! xvimagesink demux. ! queue ! adpcmdec ! audioconvert ! autoaudiosink
Thanks for your response. When I use manual pipeline, i can succeed to decode. But it's very difficult to designate the optimal demux and decoder for avi and other problem files. As I know *deocdebin* uses autoplugging to select best cases. so I select the gstreamer for deocding, encoding, play solutions. But *decodebin* can't decode some files like this, I have to consider another solutions ^^;; What is the best solution to avoid decoding problem? Can I use "gst-launch-1.0 filesrc ! decodebin" *latest* version for this problem? What plugin should I update? Now I'm using v1.7.1 (gstreamer, base, good, bad, ugly, libav) plugins. Best Regards, Keunbaek Park.
Please could you answer my question in comment #1?
(In reply to Tim-Philipp Müller from comment #4) > Please could you answer my question in comment #1? where can I download foo.avi file?
Use 04317.avi, your file that you say doesn't work.
(In reply to Tim-Philipp Müller from comment #6) > Use 04317.avi, your file that you say doesn't work. my linux system doesn't support playback gui. below is execution log. Are the decoding logic between decodebin and playbin different? gst-play-1.0 ./031002134b0e73685d73db95032c3d33124_yds04317.avi Press 'k' to see a list of keyboard shortcuts. Now playing /home1/irteam/apps/gstreamer/testfiles/testfolder/backup/16_xvid_msadpcm/031002134b0e73685d73db95032c3d33124_yds04317.avi Prerolling... (gst-play-1.0:3804): GStreamer-WARNING **: Trying to set string on structure field 'debug', but string is not valid UTF-8. Please file a bug. Redistribute latency... (gst-play-1.0:3804): GStreamer-WARNING **: Trying to set string on structure field 'debug', but string is not valid UTF-8. Please file a bug. 0:01:41.2 / 0:01:41.2 Reached end of play list. Thanks.
playbin and decodebin work the same yes. I currently see no indication of any problems, could you clarify what the problem is exactly? Does this work: gst-launch-1.0 uridecodebin uri=file:///path/to/yds04317.avi ! progressreport ! fakesink ?
(In reply to Tim-Philipp Müller from comment #8) > playbin and decodebin work the same yes. > > I currently see no indication of any problems, could you clarify what the > problem is exactly? > > Does this work: > > gst-launch-1.0 uridecodebin uri=file:///path/to/yds04317.avi ! > progressreport ! fakesink > > ? my test result. uridecodebin and decodebin results are different. I stopped decodebin manually. # gst-launch-1.0 uridecodebin uri=file:///04317.avi ! progressreport ! fakesink Setting pipeline to PAUSED ... Pipeline is PREROLLING ... Redistribute latency... 0:00:00.043744691 4847 0x7f0ce40048a0 ERROR libav :0:: Context scratch buffers could not be allocated due to unknown size. Pipeline is PREROLLED ... Setting pipeline to PLAYING ... New clock: GstSystemClock progressreport0 (00:00:01): 101 / 101 seconds (100.0 %) Got EOS from element "pipeline0". Execution ended after 1229284808 ns. Setting pipeline to PAUSED ... Setting pipeline to READY ... Setting pipeline to NULL ... Freeing pipeline ... # gst-launch-1.0 decodebin location=04317.avi ! progressreport ! fakesink Setting pipeline to PAUSED ... Pipeline is PREROLLING ... ^CCaught interrupt -- handling interrupt. Interrupt: Stopping pipeline ... (gst-launch-1.0:4878): GLib-CRITICAL **: Source ID 1 was not found when attempting to remove it ERROR: pipeline doesn't want to preroll. Setting pipeline to NULL ... Freeing pipeline ... Can I decode with decodebin? #gst-launch-1.0 filesrc location=04317.avi ! decodebin name="decode" decode. ! videoconvert ! videoscale ! x264enc ! queue ! mp4mux name="mux" ! filesink location="result.mp4" --gst-debug-level=3
> # gst-launch-1.0 decodebin location=04317.avi ! progressreport ! fakesink > Setting pipeline to PAUSED ... > Pipeline is PREROLLING ... > ^CCaught interrupt -- handling interrupt. > Interrupt: Stopping pipeline ... This pipeline makes no sense. decodebin has no location property, and you need to feed data into decodebin from a filesrc or some other source, which you're not. As far as I can tell there is no bug here, but a usage issue. Please take this to the gstreamer-devel mailing list for further advice on that, thanks.