GNOME Bugzilla – Bug 584441
[playbin2] if suburi preroll fails with error, playback should continue
Last modified: 2009-12-04 15:30:27 UTC
Please describe the problem: i find it unsatisfying that when adding a suburi srt subtitle file to a playbin2 pipeline, the playback will fail to preroll in case the srt file has a non-utf8 character set. i work on the dreambox again, with our minimal embedded linux environment and we only ship the distro with utf and 8859-15 gconv charmaps. when having an srt file in cp1250 encoding i get the described problem, even if cp1250 gconv table is installed. Steps to reproduce: gst-launch playbin2 uri=file:///media/hdd/movie/avi/coa-dragonevo-xvid.avi suburi=file:///media/hdd/movie/avi/coa-dragonevo-xvid.srt Actual results: Setting pipeline to PAUSED ... ERROR: Pipeline doesn't want to pause. ERROR: from element /GstPlayBin2:playbin20/GstURIDecodeBin:uridecodebin1/GstDecodeBin2:decodebin20/GstTypeFindElement:typefind: Could not determine type of stream. Additional debug info: gsttypefindelement.c(888): gst_type_find_element_activate (): /GstPlayBin2:playbin20/GstURIDecodeBin:uridecodebin1/GstDecodeBin2:decodebin20/GstTypeFindElement:typefind Setting pipeline to NULL ... Freeing pipeline ... Expected results: i'd be happy if the playback would start anyways, ignoring the undeterminable text stream and maybe posting a message on the bus Does this happen every time? yes, even though root@dm8000:/media/hdd/movie/avi# ipkg list_installed | grep 1250 glibc-charmap-cp1250 - 2.3.5+cvs20051107-r0 - glibc-gconv-cp1250 - 2.3.5+cvs20051107-r0 - and also with specifying "subtitle-encoding=CP1250" Other information: actual srt file to be uploaded
Created attachment 135721 [details] cp1250 polish subtitle file
Easy test case for those of us with proper iconv support: gst-launch-0.10 playbin2 uri=file:///path/to/foo.avi suburi=file:///dev/urandom fails because typefinding of the suburi stream fails. The old playbin just ignores the subtitle stream in that case and continues playing the main file.
This is already fixed. Maybe the same commit of Mike for https://bugzilla.gnome.org/show_bug.cgi?id=386504 fixed it.
Does still not work for me: $ head --bytes=50k /dev/urandom > /home/tpm/urandom.dat $ gst-launch-0.10 playbin2 uri=file:///home/tpm//foo.avi suburi=file:///home/tpm/urandom.dat Setting pipeline to PAUSED ... ERROR: Pipeline doesn't want to pause. WARNING: from element /GstURIDecodeBin:uridecodebin1/GstDecodeBin2:decodebin20/GstTypeFindElement:typefind: Could not determine type of stream. Additional debug info: gsttypefindelement.c(888): gst_type_find_element_activate (): /GstPlayBin2:playbin20/GstURIDecodeBin:uridecodebin1/GstDecodeBin2:decodebin20/GstTypeFindElement:typefind
reopening it.
Hrm, normally playbin2 should just ignore every error for the suburidecodebin, convert them to a warning and continue playback. In my tests while adding this behaviour it worked. I'll investigate later :)
The problem here is that the suburidecodebin fails to change state and thus all playbin2 fails to change state.
AFAIK typefind does it work and posts the error message on the state change call, so removing the whole uridecodebin of the subtitles on the error message handling in playbin2 doesn't prevent it of returning the state changed error to gstbin's default state_change function, causing the whole pipeline to fail
Created attachment 149094 [details] [review] bin: Ignore state change failures from children that were removed from the bin already Fixes bug #584441.