gtk4: Don't unnecessarily set the sink to READY to retrieve the context

That's not needed and will cause the GL context messages to be not
distributed inside the pipeline.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1099>
This commit is contained in:
Sebastian Dröge 2023-02-21 21:33:29 +02:00
parent 8aa5125d5b
commit f08b65ece1

View file

@ -24,8 +24,6 @@ fn create_ui(app: &gtk::Application) {
.build()
.unwrap();
// Need to set state to Ready to get a GL context
gtksink.set_state(gst::State::Ready).unwrap();
let paintable = gtksink.property::<gdk::Paintable>("paintable");
// TODO: future plans to provide a bin-like element that works with less setup