Set sync=false in rsfilesink / s3sink

BaseSink defaults to sync=true and that doesn't make much sense for
these elements.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1376>
This commit is contained in:
Sebastian Dröge 2023-10-30 17:38:46 +02:00
parent 855b03a9ea
commit 16c00ae3f5
2 changed files with 14 additions and 0 deletions

View file

@ -13,6 +13,7 @@
use gst::glib;
use gst::prelude::*;
use gst::subclass::prelude::*;
use gst_base::prelude::*;
use gst_base::subclass::prelude::*;
use std::fs::File;
@ -111,6 +112,12 @@ impl ObjectSubclass for FileSink {
}
impl ObjectImpl for FileSink {
fn constructed(&self) {
self.parent_constructed();
self.obj().set_sync(false);
}
fn properties() -> &'static [glib::ParamSpec] {
static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| {
vec![glib::ParamSpecString::builder("location")

View file

@ -9,6 +9,7 @@
use gst::glib;
use gst::prelude::*;
use gst::subclass::prelude::*;
use gst_base::prelude::*;
use gst_base::subclass::prelude::*;
use aws_sdk_s3::{
@ -655,6 +656,12 @@ impl ObjectSubclass for S3Sink {
}
impl ObjectImpl for S3Sink {
fn constructed(&self) {
self.parent_constructed();
self.obj().set_sync(false);
}
fn properties() -> &'static [glib::ParamSpec] {
static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| {
vec![