GNOME Bugzilla – Bug 650503
[dvdemux] Broken DURATION query handling
Last modified: 2011-07-27 10:10:24 UTC
My name is Carles and I'm a programmer from Barcelona. I'm doing some tests with mxf files generated with a Matrox DSX card (Broadcasting) and I'm having some problems with the MXF files with OP-Atom format. The files with a DV stream the problems seems to be only in the duration extraction, but with the AVCIntra files the demuxer also is not able to extract the correct stream properties. In http://www.megaupload.com/?f=AAN8TD5U there are some sample files Thanks a lot
What do you mean by having problems with duration extraction and stream properties? What commands/pipelines are you running?
I'm using a simple uridecodebin connected to fakesink. I use this pipe for extracting entire stream and wrapper information. After the pipe is paused I call "gst_element_query_duration" and for this kind of files the function files. With MXF files OP-1A it works fine. In fact it works fine for all kind of files OP-1A.
I have found the problem: When I call gst_element_query_duration(pipe, ... ) the first GstElement who try to extracts duration is the "dvdemux" This elements changes the duration format query to GST_FORMAT_BYTES, and the "mxfdemux" doesn't support this type of duration format. I don`t know why it happens only for OPAtom files and not for the rest. With an Op1A file the first GstElement that try to resolve the query is the "mxfdemux" and everything works fine. The workaround is to query the duration directly to the demuxer if the query to the pipe fails. Anybody knows the reason because of this? For the MXF OPAtom AVCIntra files seems that exists another problem. The essence_container for this kind of files is not recognized, and the Caps are built with the entire essence "video/x-mxf-...." I'm using my own dvdemux filter. The default one only works for dvcam streams and it cannot be connected to the "mxfdemux" Thanks a lot.
Confirmed, dvdemux should first ask the peer in the orginal format instead of just converting to BYTES
This should fix it: http://cgit.freedesktop.org/gstreamer/gst-plugins-good/commit/?id=252c1afcc2df8c8daafd98c45974c55f931d0a9f commit 252c1afcc2df8c8daafd98c45974c55f931d0a9f Author: Sebastian Dröge <sebastian.droege@collabora.co.uk> Date: Thu Jun 2 13:38:30 2011 +0200 dvdemux: First query the peer duration in the requested format before converting to BYTES Fixes usage of dvdemux after another demuxer, e.g. mxfdemux. Fixes bug #650503.
Thaks a lot. About the AVCintra issue, I have found the solution but I'm not sure. In the function "mxf_is_mpeg_essence_track" acording to the table in the table "SMPTE 381M 7" the key[13] value for the AVCIntra files is 0x10. I have the pdf and this value doesn't appears, but if I add to the condition the key->u[13] == 0x10 it works. In fact, after, when it build the capabilities, int the "mxf_mpeg_create_caps" the 0x10 value is considered. What do you think about it?
(In reply to comment #6) > Thaks a lot. > ... > What do you think about it? It's probably better to handle this in a new bug.