Verified Commit b7eb863c authored by Felix Häcker's avatar Felix Häcker

Use buffering. #440

parent 74be6bfd
Pipeline #171495 passed with stages
in 31 minutes and 57 seconds
......@@ -379,6 +379,17 @@ impl GstreamerBackend {
}
}
}
MessageView::Buffering(buffering) => {
let percent = buffering.get_percent();
info!("Buffering ({}%)\r", percent);
// Wait until buffering is complete before start/resume playing
if percent < 100 {
let _ = pipeline.set_state(State::Paused);
} else {
let _ = pipeline.set_state(State::Playing);
}
}
MessageView::Error(err) => {
let msg = err.get_error().to_string();
warn!("Gstreamer Error: {:?}", msg);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment