[gstreamer-bugs] [Bug 589110] New: can't avidemux video/mpeg mpegversion 4 stream

GStreamer (bugzilla.gnome.org) bugzilla-daemon at bugzilla.gnome.org
Mon Jul 20 03:31:59 PDT 2009


If you have any questions why you received this email, please see the text at
the end of this email. Replies to this email are NOT read, please see the text
at the end of this email. You can add comments to this bug at:
  http://bugzilla.gnome.org/show_bug.cgi?id=589110

  GStreamer | gst-plugins-good | Ver: 0.10.8
           Summary: can't avidemux video/mpeg mpegversion 4 stream
           Product: GStreamer
           Version: 0.10.8
          Platform: Other
        OS/Version: Linux
            Status: UNCONFIRMED
          Severity: normal
          Priority: Normal
         Component: gst-plugins-good
        AssignedTo: gstreamer-bugs at lists.sourceforge.net
        ReportedBy: philipperenardier at yahoo.fr
         QAContact: gstreamer-bugs at lists.sourceforge.net
     GNOME version: Unspecified
   GNOME milestone: Unspecified


I have 4 custom gst plugins and these pipelines works fine :
gst-launch-0.10 Custom_VideoSrc ! Custom_mpegversion4_coder ! queue2 ! filesink
location=test.mpeg4
and
gst-launch-0.10 filesrc location=test.mpeg4 ! queue !
Custom_mpegversion4_decoder ! Custom_VideoSink.

But i have problems with avimux/demux :

1) I got an AVI file with this pipeline: (I did care that linked pads have
compatibles templates).

gst-launch-0.10 Custom_VideoSrc ! Custom_mpegversion4_coder ! queue2 !
m.video_00 avimux name=m ! filesink location=test.avi

My Custom_mpegversion4_coder had set these caps on the buffers :
    GstCaps *outcaps = gst_caps_new_simple("video/mpeg",
                                           "mpegversion", G_TYPE_INT, 4,
                                           "framerate", GST_TYPE_FRACTION,
25,1,
                                           "width", G_TYPE_INT,720, 
                                           "height", G_TYPE_INT,576, 
                                            NULL);
which belongs to templates of both avimux and avidemux (I saw this with
gst-inspect).

I can play the file with : ffplay test.avi but the pipeline 
gst-launch-0.10 filesrc location=test.avi ! avidemux name=m  m.video_00 ! queue
! Custom_mpegversion4_decoder ! Custom_VideoSink

ends with the error : 

Setting pipeline to PAUSED 
Pipeline is PREROLLING 
ERROR: from element /pipeline0/m: Internal data stream error.                   
Additional debug info:  gstavidemux.c(4153): gst_avi_demux_loop ():
/pipeline0/m:                                                                  
streaming stopped, reason not-linked 
ERROR: pipeline doesn't want to preroll. 
Setting pipeline to NULL ... 

I saw with the debugger that the issue is the instruction : res =
gst_avi_demux_stream_data (avi); (in gst_avi_demux_loop)

2) I got an other AVI file with the same pipeline but this time my
Custom_mpegversion4_coder set these caps on the buffers :
    GstCaps *outcaps = gst_caps_new_simple("video/x-xvid",
                                           "framerate", GST_TYPE_FRACTION,
25,1,
                                           "width", G_TYPE_INT,720, 
                                           "height", G_TYPE_INT,576, 
                                            NULL);
I could play this new AVI file with the pipeline gst-launch-0.10 filesrc
location=test.avi ! avidemux name=m  m.video_00 ! queue ! xviddec ! ximagesink
wich worked fine.
(the pipeline gst-launch-0.10 filesrc location=test.avi ! avidemux name=m 
m.video_00 ! queue ! Custom_mpegversion4_decoder ! Custom_VideoSink
did not work because Custom_mpegversion4_decoder is not a xvid decoder and
avimux has set xvid tags on the stream).

3) My conclusion is that avimux and avidemux process the same way some mime
types and not the same way some others. Can somebody fixes the issue ?
Thanks for any help.

PS. I use also PCM audio compression. avidemux process PCM mime type (a-law and
mu-law) but not avimux. 
Is it scheduled that avimux and avidemux have symetric caps ?

=========== debug log (first call to gst_avi_demux_loop is OK. Second is
faulty) ==========
[New Thread 1127]
Detaching after fork from child process 1128.
Breakpoint 2 at 0x40425828: file gstavidemux.c, line 4080.
Pending breakpoint "gst_avi_demux_loop" resolved
[New Thread 1129]
[New Thread 1130]
[Switching to Thread 1130]

Breakpoint 2, gst_avi_demux_loop (pad=0x4a0d0) at gstavidemux.c:4080
4080      GstAviDemux *avi = GST_AVI_DEMUX (GST_PAD_PARENT (pad));
Breakpoint 3 at 0x404116f8: file gstavidemux.c, line 43.
(gdb) break 4126
Breakpoint 4 at 0x40425b50: file gstavidemux.c, line 4126.
(gdb) next
4082      switch (avi->state) {
(gdb) next
4084          if ((res = gst_avi_demux_stream_init_pull (avi)) != GST_FLOW_OK)
{
(gdb) next
4088          avi->state = GST_AVI_DEMUX_HEADER;
(gdb) next
4091          if ((res = gst_avi_demux_stream_header_pull (avi)) !=
GST_FLOW_OK) {
(gdb) next
4095          avi->state = GST_AVI_DEMUX_MOVI;
(gdb) next
4096          break;
(gdb) next
4120      GST_LOG_OBJECT (avi, "state: %d res:%s", avi->state,
gst_flow_get_name (res));
(gdb) cont
Continuing.

Breakpoint 2, gst_avi_demux_loop (pad=0x4a0d0) at gstavidemux.c:4080
4080      GstAviDemux *avi = GST_AVI_DEMUX (GST_PAD_PARENT (pad));
(gdb) next
4082      switch (avi->state) {
(gdb) next
4098          if (G_UNLIKELY (avi->seek_event)) {
(gdb) next
4099            gst_avi_demux_push_event (avi, avi->seek_event);
(gdb) next
4100            avi->seek_event = NULL;
(gdb) next
4102          if (G_UNLIKELY (avi->got_tags)) {
(gdb) next
4103            push_tag_lists (avi);
(gdb) next
4106          res = gst_avi_demux_stream_data (avi);
(gdb) next
4109          if (res != GST_FLOW_OK) {
(gdb) cont
Continuing.

4126      GST_LOG_OBJECT (avi, "pausing task, reason %s", gst_flow_get_name
(res));
(gdb) break 4127
Breakpoint 6 at 0x40425bb8: file gstavidemux.c, line 4127.
(gdb) cont
Continuing.

4127      avi->segment_running = FALSE;
(gdb) next
4128      gst_pad_pause_task (avi->sinkpad);
(gdb) next
4130      if (GST_FLOW_IS_FATAL (res) || (res == GST_FLOW_NOT_LINKED)) {
(gdb) break 4131
Breakpoint 7 at 0x40425bec: file gstavidemux.c, line 4131.
(gdb) cont
Continuing.

4131        gboolean push_eos = TRUE;
(gdb) next
4133        if (res == GST_FLOW_UNEXPECTED) {
(gdb) next
4151          GST_ELEMENT_ERROR (avi, STREAM, FAILED,
(gdb) break 4155
Breakpoint 8 at 0x40425e90: file gstavidemux.c, line 4155.
(gdb) cont
Continuing.

4155        if (push_eos) {
(gdb) next
4156          GST_INFO_OBJECT (avi, "sending eos");
(gdb) break 4157
Breakpoint 9 at 0x40425ef8: file gstavidemux.c, line 4157.
(gdb) cont
Continuing.

4157          if (!(gst_avi_demux_push_event (avi, gst_event_new_eos ()))) {
(gdb) next
4159            GST_ELEMENT_ERROR (avi, STREAM, FAILED,
(gdb) break 4165
Breakpoint 10 at 0x40426078: file gstavidemux.c, line 4165.
(gdb) cont
Continuing.
[Thread 1129 exited]

4165    }
(gdb) next
gst_task_func (task=0x8dc68, tclass=0x21158) at gsttask.c:194
194         GST_OBJECT_LOCK (task);
(gdb)


-- 
See http://bugzilla.gnome.org/page.cgi?id=email.html for more info about why you received
this email, why you can't respond via email, how to stop receiving
emails (or reduce the number you receive), and how to contact someone
if you are having problems with the system.

You can add comments to this bug at http://bugzilla.gnome.org/show_bug.cgi?id=589110.




More information about the Gstreamer-bugs mailing list