GNOME Bugzilla – Bug 328531
[matroskamux] doesn't send newsegment event, critical warnings from sinks
Last modified: 2006-02-06 14:30:45 UTC
Please describe the problem: (gst-launch-0.10:740): GStreamer-CRITICAL **: gst_segment_set_newsegment: assert ion `segment->format == format' failed Steps to reproduce: 1. gst-launch filesrc location=ccc.ogg ! decodebin name=decoder decoder. ! queue! audioconvert ! vorbisenc ! matroskamux ! filesink location=rip.mkv 2. gst-launch filesrc location=ccc.ogg ! decodebin name=decoder decoder. ! ffmpegcolorspace ! xvidenc ! matroskamux ! filesink location=rip.mkv 3. Actual results: (gst-launch-0.10:740): GStreamer-CRITICAL **: gst_segment_set_newsegment: assert ion `segment->format == format' failed Expected results: Does this happen every time? yes Other information: recompiled matroskamux with -g flag in ebml-write.c (line 390) seek = gst_event_new_new_segment (FALSE, 1.0, GST_FORMAT_BYTES, pos, -1, 0); peer_pad = GST_PAD_PEER (ebml->srcpad); if (peer_pad) { gst_pad_send_event (peer_pad, seek); <--- problem is from here } else { GST_WARNING_OBJECT (ebml, "Can not seek: no peer pad");
I am running gstreamer 0.10 on windows, matroska plugin is from cvs thought
could you attach a compressed debug log ? gst-launch --gst-debug=*:5 .... > log 2>&1 gzip log
Created attachment 58090 [details] log dump E:\videos>gst-launch --gst-debug=*:5 filesrc location=ccc.ogg ! decodebin name=d ecoder decoder. ! queue ! audioconvert ! vorbisenc ! matroskamux ! filesink loca tion=rip.mkv > log 2>&1 Program crashed so not sure if log is useful
can you resubmit, but this time also give the backtrace :) It doesn't seem to first the same error as in bug description.
(In reply to comment #4) > can you resubmit, but this time also give the backtrace :) It doesn't seem to > first the same error as in bug description. > Not sure how to do backtrace :( I set my env to G_DEBUG=fatal_warnings then i run gst-launch-0.10 in gdb with filesrc location=ccc.ogg ! decodebin name=decoder decoder. ! queue! audioconvert ! vorbisenc ! matroskamux ! filesink location=rip.mkv gdb catches the critical error I go bt in gdb
+ Trace 65622
Error: Previous frame inner to this frame (corrupt stack?) when i climb the stack Error is being triggered in gstbasesink.c 604 /* the newsegment event is needed to bring the buffer timestamps to the 605 * stream time and to drop samples outside of the playback segment. */ - 606 gst_event_parse_new_segment (event, &update, &rate, &format, 607 &start, &stop, &time); 608 - 609 basesink->have_newsegment = TRUE; 610 - 611 gst_segment_set_newsegment (&basesink->segment, update, rate, format, 612 start, stop, time); <----------- trigger 613 - 614 GST_DEBUG_OBJECT (basesink, 615 "received NEWSEGMENT %" GST_TIME_FORMAT " -- %" 616 GST_TIME_FORMAT ", time %" GST_TIME_FORMAT ", accum %" 617 GST_TIME_FORMAT, 618 GST_TIME_ARGS (basesink->segment.start), 619 GST_TIME_ARGS (basesink->segment.stop), 620 GST_TIME_ARGS (basesink->segment.time), 621 GST_TIME_ARGS (basesink->segment.accum)); 622 break; 623 } This is happening because on about line 615 format = GST_FORMAT_BYTES segment->format = GST_FORMAT_TIME (it got set before somehow ? ) The place where it is trigger in matroska is in ebml-write.c 386 - 387 seek = gst_event_new_new_segment (FALSE, 1.0, GST_FORMAT_BYTES, pos, -1, 0); - 388 peer_pad = GST_PAD_PEER (ebml->srcpad); - 389 if (peer_pad) { - 390 gst_pad_send_event (peer_pad, seek); <----- trigger 391 } else { - 392 GST_WARNING_OBJECT (ebml, "Can not seek: no peer pad"); 393 } 394 - 395 ebml->pos = pos; I am running windowsxp (is that a factor ?) oggfile ccc.ogg has both video and audio in it, but when i replace matroskamux with oggmux it works fine. It seems to me as in the basesink->segment is being set or initialize in GST_FORMAT_TIME, then matroska comes allong and trys to set it in GST_FORMAT_BYTES and it gets upset :(. Anyway I hope the info is helpful since I am not sure what u mean by backtrace.
Should be fixed in CVS, please re-open if it's not. 2006-02-06 Tim-Philipp Müller <tim at centricular dot net> * gst/matroska/ebml-write.c: (gst_ebml_write_reset), (gst_ebml_write_flush_cache), (gst_ebml_write_element_push), (gst_ebml_write_seek): * gst/matroska/ebml-write.h: Make sure we send a newsegment event in BYTES format before sending buffers (#328531).