Ported from GStreamer 0.10 to GStreamer 1.0