gst-launch error handling
Florian Lindner
mailinglists at xgm.de
Wed Dec 14 08:36:51 PST 2011
Ok, it works this way now, Thanks!
One more question: On a successful convert I get a None Message:
(Pdb) msg
<gst.Message (none) from pipeline0 at 0x18e2080>
Stupid question... but how do I actually test for that message?
Florian
2011/12/14 Tim-Philipp Müller <t.i.m at zen.co.uk>:
> On Wed, 2011-12-14 at 14:49 +0100, Florian Lindner wrote:
>
>> Ok, based on your code I created:
>>
>>
>> import gst
>>
>> pipe_desc = "filesrc location=accept.flac ! decodebin ! audioconvert !
>> lamemp3enc ! xingmux ! id3v2mux ! filesink location=out.mp3"
>>
>> pipeline = gst.parse_launch(pipe_desc)
>> print pipeline
>> bus = pipeline.get_bus()
>> print bus
>> msg = bus.poll(gst.MESSAGE_EOS | gst.MESSAGE_ERROR, -1)
>> print msg
>>
>> timed_pop seems to be existing somewhere, but I was unable to find
>> documentation on it.
>> The code blocks forever at bus.poll and creates no output file:
>
> You'll also have to set the pipeline to playing state before doing the
> poll(), with pipeline.set_state(gst.STATE_PLAYING) or so.
>
> Cheers
> -Tim
>
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
More information about the gstreamer-devel
mailing list