Gst.Bus.prototype.timed_pop

function timed_pop(timeout:Gst.ClockTime):Gst.Message {
    // Gjs wrapper for gst_bus_timed_pop()
}

Get a message from the bus, waiting up to the specified timeout.

If timeout is 0, this function behaves like Gst.Bus.prototype.pop. If timeout is #GST_CLOCK_TIME_NONE, this function will block forever until a message was posted on the bus.

timeout

a timeout

Returns

the Gst.Message that is on the bus after the specified timeout or NULL if the bus is empty after the timeout expired. The message is taken from the bus and needs to be unreffed with gst_message_unref() after usage. MT safe.