Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.freedesktop.org/gstreamer/gst-plugins-rs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastian Dröge <sebastian@centricular.com>2023-03-09 17:46:52 +0300
committerSebastian Dröge <sebastian@centricular.com>2023-03-09 17:46:52 +0300
commitfc5ed15af584770bdca21a3439ba9c368707ec42 (patch)
tree1ae97c6c955b77f2f15dd3783c25a171d45c8da0 /generic
parentb9cd71d8ebb904e043e109578bba73c1f5c849b4 (diff)
Update for `gst::Element::link_many()` and related API generalization
Specifically, get rid of now unneeded `&`.
Diffstat (limited to 'generic')
-rw-r--r--generic/threadshare/tests/jitterbuffer.rs8
-rw-r--r--generic/threadshare/tests/pipeline.rs14
-rw-r--r--generic/threadshare/tests/proxy.rs10
-rw-r--r--generic/threadshare/tests/queue.rs2
-rw-r--r--generic/threadshare/tests/tcpclientsrc.rs2
5 files changed, 18 insertions, 18 deletions
diff --git a/generic/threadshare/tests/jitterbuffer.rs b/generic/threadshare/tests/jitterbuffer.rs
index 687ce5f84..851d66a3b 100644
--- a/generic/threadshare/tests/jitterbuffer.rs
+++ b/generic/threadshare/tests/jitterbuffer.rs
@@ -91,9 +91,9 @@ fn jb_pipeline() {
.build();
pipeline
- .add_many(&[&src, &enc, &pay, &jb, &depay, &dec, sink.upcast_ref()])
+ .add_many([&src, &enc, &pay, &jb, &depay, &dec, sink.upcast_ref()])
.unwrap();
- gst::Element::link_many(&[&src, &enc, &pay, &jb, &depay, &dec, sink.upcast_ref()]).unwrap();
+ gst::Element::link_many([&src, &enc, &pay, &jb, &depay, &dec, sink.upcast_ref()]).unwrap();
let (sender, receiver) = mpsc::channel();
sink.set_callbacks(
@@ -175,7 +175,7 @@ fn jb_ts_pipeline() {
.build();
pipeline
- .add_many(&[
+ .add_many([
&src,
&queue,
&enc,
@@ -186,7 +186,7 @@ fn jb_ts_pipeline() {
sink.upcast_ref(),
])
.unwrap();
- gst::Element::link_many(&[
+ gst::Element::link_many([
&src,
&queue,
&enc,
diff --git a/generic/threadshare/tests/pipeline.rs b/generic/threadshare/tests/pipeline.rs
index 6b9f55343..91e5882a8 100644
--- a/generic/threadshare/tests/pipeline.rs
+++ b/generic/threadshare/tests/pipeline.rs
@@ -85,9 +85,9 @@ fn multiple_contexts_queue() {
.build();
pipeline
- .add_many(&[&src, &queue, sink.upcast_ref()])
+ .add_many([&src, &queue, sink.upcast_ref()])
.unwrap();
- gst::Element::link_many(&[&src, &queue, sink.upcast_ref()]).unwrap();
+ gst::Element::link_many([&src, &queue, sink.upcast_ref()]).unwrap();
let sender_clone = sender.clone();
sink.set_callbacks(
@@ -230,7 +230,7 @@ fn multiple_contexts_proxy() {
.build();
pipeline
- .add_many(&[&src, &proxysink, &proxysrc, sink.upcast_ref()])
+ .add_many([&src, &proxysink, &proxysrc, sink.upcast_ref()])
.unwrap();
src.link(&proxysink).unwrap();
proxysrc.link(&sink).unwrap();
@@ -353,9 +353,9 @@ fn eos() {
.build();
pipeline
- .add_many(&[&src, &queue, sink.upcast_ref()])
+ .add_many([&src, &queue, sink.upcast_ref()])
.unwrap();
- gst::Element::link_many(&[&src, &queue, sink.upcast_ref()]).unwrap();
+ gst::Element::link_many([&src, &queue, sink.upcast_ref()]).unwrap();
let (sample_notifier, sample_notif_rcv) = mpsc::channel();
let (eos_notifier, eos_notif_rcv) = mpsc::channel();
@@ -487,9 +487,9 @@ fn premature_shutdown() {
.build();
pipeline
- .add_many(&[&src, &queue, sink.upcast_ref()])
+ .add_many([&src, &queue, sink.upcast_ref()])
.unwrap();
- gst::Element::link_many(&[&src, &queue, sink.upcast_ref()]).unwrap();
+ gst::Element::link_many([&src, &queue, sink.upcast_ref()]).unwrap();
let (appsink_sender, appsink_receiver) = mpsc::channel();
diff --git a/generic/threadshare/tests/proxy.rs b/generic/threadshare/tests/proxy.rs
index 49eb64e6a..f7992eed0 100644
--- a/generic/threadshare/tests/proxy.rs
+++ b/generic/threadshare/tests/proxy.rs
@@ -54,7 +54,7 @@ fn test_push() {
let appsink = gst_app::AppSink::builder().build();
pipeline
- .add_many(&[&fakesrc, &proxysink, &proxysrc, appsink.upcast_ref()])
+ .add_many([&fakesrc, &proxysink, &proxysrc, appsink.upcast_ref()])
.unwrap();
fakesrc.link(&proxysink).unwrap();
proxysrc.link(&appsink).unwrap();
@@ -122,10 +122,10 @@ fn test_from_pipeline_to_pipeline() {
.unwrap();
let fakesink = gst::ElementFactory::make("fakesink").build().unwrap();
- pipe_1.add_many(&[&fakesrc, &pxsink]).unwrap();
+ pipe_1.add_many([&fakesrc, &pxsink]).unwrap();
fakesrc.link(&pxsink).unwrap();
- pipe_2.add_many(&[&pxsrc, &fakesink]).unwrap();
+ pipe_2.add_many([&pxsrc, &fakesink]).unwrap();
pxsrc.link(&fakesink).unwrap();
pipe_1.set_state(gst::State::Paused).unwrap();
@@ -169,10 +169,10 @@ fn test_from_pipeline_to_pipeline_and_back() {
.build()
.unwrap();
- pipe_1.add_many(&[&pxsrc_1, &pxsink_1]).unwrap();
+ pipe_1.add_many([&pxsrc_1, &pxsink_1]).unwrap();
pxsrc_1.link(&pxsink_1).unwrap();
- pipe_2.add_many(&[&pxsrc_2, &pxsink_2]).unwrap();
+ pipe_2.add_many([&pxsrc_2, &pxsink_2]).unwrap();
pxsrc_2.link(&pxsink_2).unwrap();
pipe_1.set_state(gst::State::Paused).unwrap();
diff --git a/generic/threadshare/tests/queue.rs b/generic/threadshare/tests/queue.rs
index 321f3cd5d..28ce10ae3 100644
--- a/generic/threadshare/tests/queue.rs
+++ b/generic/threadshare/tests/queue.rs
@@ -44,7 +44,7 @@ fn test_push() {
let appsink = gst_app::AppSink::builder().build();
pipeline
- .add_many(&[&fakesrc, &queue, appsink.upcast_ref()])
+ .add_many([&fakesrc, &queue, appsink.upcast_ref()])
.unwrap();
fakesrc.link(&queue).unwrap();
queue.link(&appsink).unwrap();
diff --git a/generic/threadshare/tests/tcpclientsrc.rs b/generic/threadshare/tests/tcpclientsrc.rs
index 27c9fe1ec..a450452eb 100644
--- a/generic/threadshare/tests/tcpclientsrc.rs
+++ b/generic/threadshare/tests/tcpclientsrc.rs
@@ -68,7 +68,7 @@ fn test_push() {
.build();
pipeline
- .add_many(&[&tcpclientsrc, appsink.upcast_ref()])
+ .add_many([&tcpclientsrc, appsink.upcast_ref()])
.unwrap();
tcpclientsrc.link(&appsink).unwrap();