diff options
author | Sebastian Dröge <sebastian@centricular.com> | 2022-10-19 19:18:43 +0300 |
---|---|---|
committer | Sebastian Dröge <sebastian@centricular.com> | 2022-10-19 19:43:29 +0300 |
commit | 12400b6b87e75cfdfa7701b62cf8698c11e14a73 (patch) | |
tree | df8f49f8258a34e961b8f9710671fc0d97bf7c58 /tutorial | |
parent | 9ce8e93c6374a712a6c8981557c726a3fc04273b (diff) |
Update everything for element factory builder API changes
And set properties as part of object construction wherever it makes
sense.
Diffstat (limited to 'tutorial')
-rw-r--r-- | tutorial/src/progressbin/imp.rs | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/tutorial/src/progressbin/imp.rs b/tutorial/src/progressbin/imp.rs index 3c35ac2bc..3bc94c40e 100644 --- a/tutorial/src/progressbin/imp.rs +++ b/tutorial/src/progressbin/imp.rs @@ -63,9 +63,12 @@ impl ObjectSubclass for ProgressBin { let srcpad = gst::GhostPad::from_template(&templ, Some("src")); // Create the progressreport element. - let progress = gst::ElementFactory::make("progressreport", Some("progress")).unwrap(); - // Don't let progressreport print to stdout itself - progress.set_property("silent", true); + let progress = gst::ElementFactory::make("progressreport") + .name("progress") + // Don't let progressreport print to stdout itself + .property("silent", true) + .build() + .unwrap(); // Return an instance of our struct Self { |