From 8dfc872544b26aa5eaf4b12da7d9c5e0361467ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Laignel?= Date: Thu, 3 Jun 2021 20:20:54 +0200 Subject: [PATCH] use gst::glib where applicable --- audio/audiofx/Cargo.toml | 1 - audio/audiofx/src/audioecho/imp.rs | 2 +- audio/audiofx/src/audioecho/mod.rs | 3 +- audio/audiofx/src/audioloudnorm/imp.rs | 2 +- audio/audiofx/src/audioloudnorm/mod.rs | 3 +- audio/audiofx/src/audiornnoise/imp.rs | 2 +- audio/audiofx/src/audiornnoise/mod.rs | 3 +- audio/audiofx/src/ebur128level/imp.rs | 2 +- audio/audiofx/src/ebur128level/mod.rs | 3 +- audio/audiofx/src/lib.rs | 2 + audio/audiofx/tests/audioloudnorm.rs | 2 +- audio/audiofx/tests/ebur128level.rs | 1 + audio/claxon/Cargo.toml | 1 - audio/claxon/src/claxondec/imp.rs | 2 +- audio/claxon/src/claxondec/mod.rs | 3 +- audio/claxon/src/lib.rs | 2 + audio/csound/Cargo.toml | 1 - audio/csound/examples/effect_example.rs | 11 ++-- audio/csound/src/filter/imp.rs | 2 +- audio/csound/src/filter/mod.rs | 3 +- audio/csound/src/lib.rs | 2 + audio/csound/tests/csound_filter.rs | 7 +-- audio/lewton/Cargo.toml | 1 - audio/lewton/src/lewtondec/imp.rs | 2 +- audio/lewton/src/lewtondec/mod.rs | 3 +- audio/lewton/src/lib.rs | 2 + generic/file/Cargo.toml | 1 - generic/file/src/file_location.rs | 1 + generic/file/src/filesink/imp.rs | 2 +- generic/file/src/filesink/mod.rs | 3 +- generic/file/src/filesrc/imp.rs | 2 +- generic/file/src/filesrc/mod.rs | 3 +- generic/file/src/lib.rs | 2 + generic/sodium/Cargo.toml | 1 - generic/sodium/examples/decrypt_example.rs | 2 +- generic/sodium/examples/encrypt_example.rs | 2 +- generic/sodium/src/decrypter/imp.rs | 3 +- generic/sodium/src/decrypter/mod.rs | 3 +- generic/sodium/src/encrypter/imp.rs | 3 +- generic/sodium/src/encrypter/mod.rs | 3 +- generic/sodium/src/lib.rs | 2 + generic/sodium/tests/decrypter.rs | 2 +- generic/sodium/tests/encrypter.rs | 2 +- generic/threadshare/Cargo.toml | 1 - generic/threadshare/examples/benchmark.rs | 2 +- generic/threadshare/src/appsrc/imp.rs | 4 +- generic/threadshare/src/appsrc/mod.rs | 3 +- generic/threadshare/src/inputselector/imp.rs | 4 +- generic/threadshare/src/inputselector/mod.rs | 3 +- generic/threadshare/src/jitterbuffer/ffi.rs | 1 + generic/threadshare/src/jitterbuffer/imp.rs | 4 +- .../src/jitterbuffer/jitterbuffer.rs | 3 +- generic/threadshare/src/jitterbuffer/mod.rs | 3 +- generic/threadshare/src/lib.rs | 1 + generic/threadshare/src/proxy/imp.rs | 4 +- generic/threadshare/src/proxy/mod.rs | 3 +- generic/threadshare/src/queue/imp.rs | 4 +- generic/threadshare/src/queue/mod.rs | 3 +- generic/threadshare/src/socket.rs | 1 + generic/threadshare/src/tcpclientsrc/imp.rs | 4 +- generic/threadshare/src/tcpclientsrc/mod.rs | 3 +- generic/threadshare/src/udpsink/imp.rs | 4 +- generic/threadshare/src/udpsink/mod.rs | 3 +- generic/threadshare/src/udpsrc/imp.rs | 4 +- generic/threadshare/src/udpsrc/mod.rs | 3 +- generic/threadshare/tests/appsrc.rs | 1 - generic/threadshare/tests/inputselector.rs | 1 - generic/threadshare/tests/pad.rs | 1 + generic/threadshare/tests/pipeline.rs | 1 + generic/threadshare/tests/proxy.rs | 1 - generic/threadshare/tests/queue.rs | 1 - generic/threadshare/tests/tcpclientsrc.rs | 1 - generic/threadshare/tests/udpsink.rs | 2 +- generic/threadshare/tests/udpsrc.rs | 2 +- net/reqwest/Cargo.toml | 1 - net/reqwest/src/lib.rs | 2 + net/reqwest/src/reqwesthttpsrc/imp.rs | 2 +- net/reqwest/src/reqwesthttpsrc/mod.rs | 3 +- net/reqwest/tests/reqwesthttpsrc.rs | 1 + net/rusoto/Cargo.toml | 1 - net/rusoto/src/aws_transcriber/imp.rs | 3 +- net/rusoto/src/aws_transcriber/mod.rs | 3 +- net/rusoto/src/lib.rs | 2 + net/rusoto/src/s3sink/imp.rs | 4 +- net/rusoto/src/s3sink/mod.rs | 3 +- net/rusoto/src/s3src/imp.rs | 5 +- net/rusoto/src/s3src/mod.rs | 3 +- text/json/Cargo.toml | 1 - text/json/src/jsongstenc/imp.rs | 2 +- text/json/src/jsongstenc/mod.rs | 3 +- text/json/src/jsongstparse/imp.rs | 3 +- text/json/src/jsongstparse/mod.rs | 3 +- text/json/src/lib.rs | 2 + text/regex/Cargo.toml | 1 - text/regex/src/gstregex/imp.rs | 3 +- text/regex/src/gstregex/mod.rs | 3 +- text/regex/src/lib.rs | 2 + text/regex/tests/regex.rs | 2 +- text/wrap/Cargo.toml | 1 - text/wrap/src/gsttextwrap/imp.rs | 3 +- text/wrap/src/gsttextwrap/mod.rs | 3 +- text/wrap/src/lib.rs | 2 + text/wrap/tests/textwrap.rs | 2 +- tutorial/Cargo.toml | 1 - tutorial/src/identity/imp.rs | 2 +- tutorial/src/identity/mod.rs | 3 +- tutorial/src/lib.rs | 2 + tutorial/src/progressbin/imp.rs | 3 +- tutorial/src/progressbin/mod.rs | 3 +- tutorial/src/rgb2gray/imp.rs | 2 +- tutorial/src/rgb2gray/mod.rs | 3 +- tutorial/src/sinesrc/imp.rs | 2 +- tutorial/src/sinesrc/mod.rs | 3 +- tutorial/tutorial-1.md | 63 ++++++++++--------- tutorial/tutorial-2.md | 18 +++--- utils/fallbackswitch/Cargo.toml | 1 - .../examples/gtk_fallbackswitch.rs | 1 + utils/fallbackswitch/src/base/aggregator.rs | 3 +- .../fallbackswitch/src/base/aggregator_pad.rs | 1 + .../src/base/auto/aggregator.rs | 1 + .../src/base/auto/aggregator_pad.rs | 1 + utils/fallbackswitch/src/base/ffi.rs | 2 +- utils/fallbackswitch/src/base/mod.rs | 2 +- .../src/base/subclass/aggregator.rs | 5 +- .../src/base/subclass/aggregator_pad.rs | 4 +- utils/fallbackswitch/src/base/utils.rs | 1 + .../src/fallbacksrc/custom_source/imp.rs | 3 +- .../src/fallbacksrc/custom_source/mod.rs | 2 + utils/fallbackswitch/src/fallbacksrc/imp.rs | 3 +- utils/fallbackswitch/src/fallbacksrc/mod.rs | 3 +- .../src/fallbacksrc/video_fallback/imp.rs | 3 +- .../src/fallbacksrc/video_fallback/mod.rs | 2 + .../fallbackswitch/src/fallbackswitch/imp.rs | 2 + .../fallbackswitch/src/fallbackswitch/mod.rs | 3 +- utils/fallbackswitch/src/lib.rs | 2 + utils/fallbackswitch/tests/fallbackswitch.rs | 1 - utils/togglerecord/Cargo.toml | 1 - utils/togglerecord/examples/gtk_recording.rs | 1 + utils/togglerecord/src/lib.rs | 2 + utils/togglerecord/src/togglerecord/imp.rs | 3 +- utils/togglerecord/src/togglerecord/mod.rs | 3 +- utils/togglerecord/tests/tests.rs | 2 - video/cdg/Cargo.toml | 1 - video/cdg/src/cdgdec/imp.rs | 2 +- video/cdg/src/cdgdec/mod.rs | 3 +- video/cdg/src/cdgparse/imp.rs | 2 +- video/cdg/src/cdgparse/mod.rs | 3 +- video/cdg/src/lib.rs | 2 + video/cdg/src/typefind.rs | 2 + video/closedcaption/Cargo.toml | 1 - video/closedcaption/src/ccdetect/imp.rs | 2 +- video/closedcaption/src/ccdetect/mod.rs | 3 +- video/closedcaption/src/cea608overlay/imp.rs | 2 +- video/closedcaption/src/cea608overlay/mod.rs | 3 +- video/closedcaption/src/cea608tojson/imp.rs | 2 +- video/closedcaption/src/cea608tojson/mod.rs | 3 +- video/closedcaption/src/cea608tott/imp.rs | 2 +- video/closedcaption/src/cea608tott/mod.rs | 3 +- video/closedcaption/src/lib.rs | 2 + video/closedcaption/src/mcc_enc/imp.rs | 3 +- video/closedcaption/src/mcc_enc/mod.rs | 3 +- video/closedcaption/src/mcc_parse/imp.rs | 3 +- video/closedcaption/src/mcc_parse/mod.rs | 3 +- video/closedcaption/src/scc_enc/imp.rs | 2 +- video/closedcaption/src/scc_enc/mod.rs | 3 +- video/closedcaption/src/scc_parse/imp.rs | 2 +- video/closedcaption/src/scc_parse/mod.rs | 3 +- video/closedcaption/src/tttocea608/imp.rs | 3 +- video/closedcaption/src/tttocea608/mod.rs | 3 +- video/closedcaption/src/tttojson/imp.rs | 2 +- video/closedcaption/src/tttojson/mod.rs | 3 +- video/closedcaption/src/ttutils.rs | 1 + video/closedcaption/tests/mcc_enc.rs | 3 +- video/dav1d/Cargo.toml | 1 - video/dav1d/src/dav1ddec/imp.rs | 2 +- video/dav1d/src/dav1ddec/mod.rs | 3 +- video/dav1d/src/lib.rs | 2 + video/flavors/Cargo.toml | 1 - video/flavors/src/flvdemux/imp.rs | 1 + video/flavors/src/flvdemux/mod.rs | 3 +- video/flavors/src/lib.rs | 2 + video/gif/Cargo.toml | 1 - video/gif/src/gifenc/imp.rs | 2 +- video/gif/src/gifenc/mod.rs | 3 +- video/gif/src/lib.rs | 2 + video/hsv/Cargo.toml | 1 - video/hsv/src/hsvdetector/imp.rs | 2 +- video/hsv/src/hsvdetector/mod.rs | 3 +- video/hsv/src/hsvfilter/imp.rs | 2 +- video/hsv/src/hsvfilter/mod.rs | 3 +- video/hsv/src/lib.rs | 2 + video/rav1e/Cargo.toml | 1 - video/rav1e/src/lib.rs | 2 + video/rav1e/src/rav1enc/imp.rs | 2 +- video/rav1e/src/rav1enc/mod.rs | 3 +- video/rav1e/tests/rav1enc.rs | 2 +- video/rspng/Cargo.toml | 1 - video/rspng/src/lib.rs | 2 + video/rspng/src/pngenc/imp.rs | 3 +- video/rspng/src/pngenc/mod.rs | 3 +- video/webp/Cargo.toml | 1 - video/webp/src/dec/imp.rs | 2 +- video/webp/src/dec/mod.rs | 3 +- video/webp/src/lib.rs | 2 + 204 files changed, 306 insertions(+), 245 deletions(-) diff --git a/audio/audiofx/Cargo.toml b/audio/audiofx/Cargo.toml index cc0aa8dc..94a00ec2 100644 --- a/audio/audiofx/Cargo.toml +++ b/audio/audiofx/Cargo.toml @@ -8,7 +8,6 @@ description = "Rust AudioFx Plugin" edition = "2018" [dependencies] -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } gst = { package = "gstreamer", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs", features = ["v1_16"] } gst-base = { package = "gstreamer-base", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs", features = ["v1_16"] } gst-audio = { package = "gstreamer-audio", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs", features = ["v1_16"] } diff --git a/audio/audiofx/src/audioecho/imp.rs b/audio/audiofx/src/audioecho/imp.rs index 08b17fed..b3524c12 100644 --- a/audio/audiofx/src/audioecho/imp.rs +++ b/audio/audiofx/src/audioecho/imp.rs @@ -6,7 +6,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst_base::subclass::prelude::*; diff --git a/audio/audiofx/src/audioecho/mod.rs b/audio/audiofx/src/audioecho/mod.rs index 2cbfd634..f33475c3 100644 --- a/audio/audiofx/src/audioecho/mod.rs +++ b/audio/audiofx/src/audioecho/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; mod ring_buffer; diff --git a/audio/audiofx/src/audioloudnorm/imp.rs b/audio/audiofx/src/audioloudnorm/imp.rs index b2eb149a..2925e774 100644 --- a/audio/audiofx/src/audioloudnorm/imp.rs +++ b/audio/audiofx/src/audioloudnorm/imp.rs @@ -18,7 +18,7 @@ // License along with FFmpeg; if not, write to the Free Software // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_info, gst_log}; diff --git a/audio/audiofx/src/audioloudnorm/mod.rs b/audio/audiofx/src/audioloudnorm/mod.rs index c49a3585..449a2a50 100644 --- a/audio/audiofx/src/audioloudnorm/mod.rs +++ b/audio/audiofx/src/audioloudnorm/mod.rs @@ -18,7 +18,8 @@ // License along with FFmpeg; if not, write to the Free Software // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/audio/audiofx/src/audiornnoise/imp.rs b/audio/audiofx/src/audiornnoise/imp.rs index 6af68e10..42efd72f 100644 --- a/audio/audiofx/src/audiornnoise/imp.rs +++ b/audio/audiofx/src/audiornnoise/imp.rs @@ -7,7 +7,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error}; diff --git a/audio/audiofx/src/audiornnoise/mod.rs b/audio/audiofx/src/audiornnoise/mod.rs index 4cc4cf76..7149f6c7 100644 --- a/audio/audiofx/src/audiornnoise/mod.rs +++ b/audio/audiofx/src/audiornnoise/mod.rs @@ -7,7 +7,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/audio/audiofx/src/ebur128level/imp.rs b/audio/audiofx/src/ebur128level/imp.rs index 233ac869..940c21d2 100644 --- a/audio/audiofx/src/ebur128level/imp.rs +++ b/audio/audiofx/src/ebur128level/imp.rs @@ -6,7 +6,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_info}; diff --git a/audio/audiofx/src/ebur128level/mod.rs b/audio/audiofx/src/ebur128level/mod.rs index 7df27dac..e84beb19 100644 --- a/audio/audiofx/src/ebur128level/mod.rs +++ b/audio/audiofx/src/ebur128level/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/audio/audiofx/src/lib.rs b/audio/audiofx/src/lib.rs index 013dd4d2..1d2cc11c 100644 --- a/audio/audiofx/src/lib.rs +++ b/audio/audiofx/src/lib.rs @@ -6,6 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. +use gst::glib; + mod audioecho; mod audioloudnorm; mod audiornnoise; diff --git a/audio/audiofx/tests/audioloudnorm.rs b/audio/audiofx/tests/audioloudnorm.rs index 00c74746..b8163359 100644 --- a/audio/audiofx/tests/audioloudnorm.rs +++ b/audio/audiofx/tests/audioloudnorm.rs @@ -14,7 +14,7 @@ // License along with this library; if not, write to the // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; + use gst::prelude::*; use byte_slice_cast::*; diff --git a/audio/audiofx/tests/ebur128level.rs b/audio/audiofx/tests/ebur128level.rs index 057a44ef..776014a6 100644 --- a/audio/audiofx/tests/ebur128level.rs +++ b/audio/audiofx/tests/ebur128level.rs @@ -6,6 +6,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. +use gst::glib; use gst::prelude::*; fn init() { diff --git a/audio/claxon/Cargo.toml b/audio/claxon/Cargo.toml index 20f9b7d6..05523f47 100644 --- a/audio/claxon/Cargo.toml +++ b/audio/claxon/Cargo.toml @@ -8,7 +8,6 @@ description = "Claxon FLAC Decoder Plugin" edition = "2018" [dependencies] -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } gst = { package = "gstreamer", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gst-audio = { package = "gstreamer-audio", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } claxon = { version = "0.4" } diff --git a/audio/claxon/src/claxondec/imp.rs b/audio/claxon/src/claxondec/imp.rs index 29fcb90e..b4e81057 100644 --- a/audio/claxon/src/claxondec/imp.rs +++ b/audio/claxon/src/claxondec/imp.rs @@ -6,7 +6,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::subclass::prelude::*; +use gst::glib; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error}; use gst_audio::prelude::*; diff --git a/audio/claxon/src/claxondec/mod.rs b/audio/claxon/src/claxondec/mod.rs index 29f5d34d..a9356ffc 100644 --- a/audio/claxon/src/claxondec/mod.rs +++ b/audio/claxon/src/claxondec/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/audio/claxon/src/lib.rs b/audio/claxon/src/lib.rs index 18039cd9..2476b877 100644 --- a/audio/claxon/src/lib.rs +++ b/audio/claxon/src/lib.rs @@ -6,6 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. +use gst::glib; + mod claxondec; fn plugin_init(plugin: &gst::Plugin) -> Result<(), glib::BoolError> { diff --git a/audio/csound/Cargo.toml b/audio/csound/Cargo.toml index 349ed15a..c809dfe4 100644 --- a/audio/csound/Cargo.toml +++ b/audio/csound/Cargo.toml @@ -8,7 +8,6 @@ edition = "2018" description = "An Audio filter plugin based on Csound" [dependencies] -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } gst = { package = "gstreamer", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gst-base = { package = "gstreamer-base", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gst-audio = { package = "gstreamer-audio", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } diff --git a/audio/csound/examples/effect_example.rs b/audio/csound/examples/effect_example.rs index 4993555a..2f8b78ab 100644 --- a/audio/csound/examples/effect_example.rs +++ b/audio/csound/examples/effect_example.rs @@ -15,7 +15,6 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; use gst::prelude::*; use std::error::Error; @@ -40,25 +39,25 @@ const CSD: &str = " sr = 44100 ksmps = 7 - nchnls_i = 1 - nchnls = 2 + nchnls_i = 1 + nchnls = 2 gasig init 0 - gidel = 1 + gidel = 1 instr 1 ain in outs ain, ain - vincr gasig, ain + vincr gasig, ain endin instr 2 ifeedback = p4 - aseg linseg 1., p3, 0.0 + aseg linseg 1., p3, 0.0 abuf2 delayr gidel adelL deltap .4 diff --git a/audio/csound/src/filter/imp.rs b/audio/csound/src/filter/imp.rs index c191a62a..08d207ad 100644 --- a/audio/csound/src/filter/imp.rs +++ b/audio/csound/src/filter/imp.rs @@ -15,7 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{ diff --git a/audio/csound/src/filter/mod.rs b/audio/csound/src/filter/mod.rs index 702d7b88..53d08385 100644 --- a/audio/csound/src/filter/mod.rs +++ b/audio/csound/src/filter/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/audio/csound/src/lib.rs b/audio/csound/src/lib.rs index 2c7f1595..1e920fbe 100644 --- a/audio/csound/src/lib.rs +++ b/audio/csound/src/lib.rs @@ -15,6 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. +use gst::glib; + mod filter; fn plugin_init(plugin: &gst::Plugin) -> Result<(), glib::BoolError> { diff --git a/audio/csound/tests/csound_filter.rs b/audio/csound/tests/csound_filter.rs index 1c054763..16907a4d 100644 --- a/audio/csound/tests/csound_filter.rs +++ b/audio/csound/tests/csound_filter.rs @@ -14,7 +14,6 @@ // License along with this library; if not, write to the // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; use gst::prelude::*; use byte_slice_cast::*; @@ -33,13 +32,13 @@ macro_rules! CSD { sr = 44100 ; default sample rate ksmps = {} - nchnls_i = {} + nchnls_i = {} nchnls = {} 0dbfs = 1 - instr 1 + instr 1 - {} ;input + {} ;input {} ; csound output endin diff --git a/audio/lewton/Cargo.toml b/audio/lewton/Cargo.toml index 6f8638ca..136fc74c 100644 --- a/audio/lewton/Cargo.toml +++ b/audio/lewton/Cargo.toml @@ -8,7 +8,6 @@ description = "lewton Vorbis Decoder Plugin" edition = "2018" [dependencies] -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } gst = { package = "gstreamer", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gst-audio = { package = "gstreamer-audio", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } lewton = { version = "0.10", default-features = false } diff --git a/audio/lewton/src/lewtondec/imp.rs b/audio/lewton/src/lewtondec/imp.rs index 26cef0c5..2902d214 100644 --- a/audio/lewton/src/lewtondec/imp.rs +++ b/audio/lewton/src/lewtondec/imp.rs @@ -6,7 +6,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::subclass::prelude::*; +use gst::glib; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_warning}; use gst_audio::audio_decoder_error; diff --git a/audio/lewton/src/lewtondec/mod.rs b/audio/lewton/src/lewtondec/mod.rs index b7cf101a..a0e7731e 100644 --- a/audio/lewton/src/lewtondec/mod.rs +++ b/audio/lewton/src/lewtondec/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/audio/lewton/src/lib.rs b/audio/lewton/src/lib.rs index fa63d81b..da5bb434 100644 --- a/audio/lewton/src/lib.rs +++ b/audio/lewton/src/lib.rs @@ -6,6 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. +use gst::glib; + mod lewtondec; fn plugin_init(plugin: &gst::Plugin) -> Result<(), glib::BoolError> { diff --git a/generic/file/Cargo.toml b/generic/file/Cargo.toml index 7da17899..3070d82a 100644 --- a/generic/file/Cargo.toml +++ b/generic/file/Cargo.toml @@ -9,7 +9,6 @@ edition = "2018" [dependencies] url = "2" -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } gst = { package = "gstreamer", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gst-base = { package = "gstreamer-base", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } once_cell = "1.0" diff --git a/generic/file/src/file_location.rs b/generic/file/src/file_location.rs index 22d4c407..8d567228 100644 --- a/generic/file/src/file_location.rs +++ b/generic/file/src/file_location.rs @@ -1,3 +1,4 @@ +use gst::glib; use url::Url; use std::convert::AsRef; diff --git a/generic/file/src/filesink/imp.rs b/generic/file/src/filesink/imp.rs index 712bd7d7..7a0dd9e7 100644 --- a/generic/file/src/filesink/imp.rs +++ b/generic/file/src/filesink/imp.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_info, gst_trace}; diff --git a/generic/file/src/filesink/mod.rs b/generic/file/src/filesink/mod.rs index 442b2fe2..d5fb310d 100644 --- a/generic/file/src/filesink/mod.rs +++ b/generic/file/src/filesink/mod.rs @@ -8,7 +8,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/generic/file/src/filesrc/imp.rs b/generic/file/src/filesrc/imp.rs index 73946590..be01cb90 100644 --- a/generic/file/src/filesrc/imp.rs +++ b/generic/file/src/filesrc/imp.rs @@ -7,7 +7,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_info}; diff --git a/generic/file/src/filesrc/mod.rs b/generic/file/src/filesrc/mod.rs index caad10ab..5e777158 100644 --- a/generic/file/src/filesrc/mod.rs +++ b/generic/file/src/filesrc/mod.rs @@ -7,7 +7,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/generic/file/src/lib.rs b/generic/file/src/lib.rs index 114deab6..04fff665 100644 --- a/generic/file/src/lib.rs +++ b/generic/file/src/lib.rs @@ -6,6 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. +use gst::glib; + mod file_location; mod filesink; mod filesrc; diff --git a/generic/sodium/Cargo.toml b/generic/sodium/Cargo.toml index 7cb0f9fa..5c0e6f0d 100644 --- a/generic/sodium/Cargo.toml +++ b/generic/sodium/Cargo.toml @@ -8,7 +8,6 @@ license = "MIT" edition = "2018" [dependencies] -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } gst = { git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs", features = ["v1_14"], package="gstreamer" } gst-base = { git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs", features = ["v1_14"], package = "gstreamer-base" } sodiumoxide = "0.2.1" diff --git a/generic/sodium/examples/decrypt_example.rs b/generic/sodium/examples/decrypt_example.rs index 78817e44..1a8a199a 100644 --- a/generic/sodium/examples/decrypt_example.rs +++ b/generic/sodium/examples/decrypt_example.rs @@ -22,7 +22,7 @@ // // SPDX-License-Identifier: MIT -use glib::prelude::*; +use gst::glib; use gst::prelude::*; use sodiumoxide::crypto::box_; diff --git a/generic/sodium/examples/encrypt_example.rs b/generic/sodium/examples/encrypt_example.rs index c4e6f66b..29aa586f 100644 --- a/generic/sodium/examples/encrypt_example.rs +++ b/generic/sodium/examples/encrypt_example.rs @@ -22,7 +22,7 @@ // // SPDX-License-Identifier: MIT -use glib::prelude::*; +use gst::glib; use gst::prelude::*; use sodiumoxide::crypto::box_; diff --git a/generic/sodium/src/decrypter/imp.rs b/generic/sodium/src/decrypter/imp.rs index 296e9655..ce8a840a 100644 --- a/generic/sodium/src/decrypter/imp.rs +++ b/generic/sodium/src/decrypter/imp.rs @@ -22,8 +22,7 @@ // // SPDX-License-Identifier: MIT -use glib::prelude::*; -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_log}; diff --git a/generic/sodium/src/decrypter/mod.rs b/generic/sodium/src/decrypter/mod.rs index 96f48a09..3875815d 100644 --- a/generic/sodium/src/decrypter/mod.rs +++ b/generic/sodium/src/decrypter/mod.rs @@ -22,7 +22,8 @@ // // SPDX-License-Identifier: MIT -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/generic/sodium/src/encrypter/imp.rs b/generic/sodium/src/encrypter/imp.rs index 849cde47..3b5bde2a 100644 --- a/generic/sodium/src/encrypter/imp.rs +++ b/generic/sodium/src/encrypter/imp.rs @@ -22,8 +22,7 @@ // // SPDX-License-Identifier: MIT -use glib::prelude::*; -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_log}; diff --git a/generic/sodium/src/encrypter/mod.rs b/generic/sodium/src/encrypter/mod.rs index be74c586..75a19cde 100644 --- a/generic/sodium/src/encrypter/mod.rs +++ b/generic/sodium/src/encrypter/mod.rs @@ -22,7 +22,8 @@ // // SPDX-License-Identifier: MIT -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/generic/sodium/src/lib.rs b/generic/sodium/src/lib.rs index 32bd7b65..6266049a 100644 --- a/generic/sodium/src/lib.rs +++ b/generic/sodium/src/lib.rs @@ -20,6 +20,8 @@ // // SPDX-License-Identifier: MIT +use gst::glib; + const TYPEFIND_HEADER: &[u8; 12] = b"gst-sodium10"; // `core::slice::::len` is not yet stable as a const fn // const TYPEFIND_HEADER_SIZE: usize = TYPEFIND_HEADER.len(); diff --git a/generic/sodium/tests/decrypter.rs b/generic/sodium/tests/decrypter.rs index 864cc04c..8feafaef 100644 --- a/generic/sodium/tests/decrypter.rs +++ b/generic/sodium/tests/decrypter.rs @@ -22,7 +22,7 @@ // // SPDX-License-Identifier: MIT -use glib::prelude::*; +use gst::glib; use gst::prelude::*; use std::sync::{Arc, Mutex}; diff --git a/generic/sodium/tests/encrypter.rs b/generic/sodium/tests/encrypter.rs index c945b077..e55c0aa4 100644 --- a/generic/sodium/tests/encrypter.rs +++ b/generic/sodium/tests/encrypter.rs @@ -22,7 +22,7 @@ // // SPDX-License-Identifier: MIT -use glib::prelude::*; +use gst::glib; use gst::prelude::*; use once_cell::sync::Lazy; diff --git a/generic/threadshare/Cargo.toml b/generic/threadshare/Cargo.toml index 6e14d207..bc04ae7b 100644 --- a/generic/threadshare/Cargo.toml +++ b/generic/threadshare/Cargo.toml @@ -9,7 +9,6 @@ edition = "2018" [dependencies] libc = "0.2" -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } gio = { git = "https://github.com/gtk-rs/gtk-rs-core" } gst = { package = "gstreamer", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs", features=["v1_10"] } gst-net = { package = "gstreamer-net", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } diff --git a/generic/threadshare/examples/benchmark.rs b/generic/threadshare/examples/benchmark.rs index 86d84d21..e01f92e0 100644 --- a/generic/threadshare/examples/benchmark.rs +++ b/generic/threadshare/examples/benchmark.rs @@ -15,7 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; use gst::prelude::*; use std::env; diff --git a/generic/threadshare/src/appsrc/imp.rs b/generic/threadshare/src/appsrc/imp.rs index bba794f9..bb0f622e 100644 --- a/generic/threadshare/src/appsrc/imp.rs +++ b/generic/threadshare/src/appsrc/imp.rs @@ -21,9 +21,7 @@ use futures::future::BoxFuture; use futures::lock::Mutex as FutMutex; use futures::prelude::*; -use glib::prelude::*; -use glib::subclass::prelude::*; - +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_log, gst_trace}; diff --git a/generic/threadshare/src/appsrc/mod.rs b/generic/threadshare/src/appsrc/mod.rs index ab965ede..47de9f67 100644 --- a/generic/threadshare/src/appsrc/mod.rs +++ b/generic/threadshare/src/appsrc/mod.rs @@ -16,7 +16,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/generic/threadshare/src/inputselector/imp.rs b/generic/threadshare/src/inputselector/imp.rs index 4d502ff6..d5dd6370 100644 --- a/generic/threadshare/src/inputselector/imp.rs +++ b/generic/threadshare/src/inputselector/imp.rs @@ -19,9 +19,7 @@ use futures::future::BoxFuture; use futures::future::{abortable, AbortHandle}; use futures::prelude::*; -use glib::prelude::*; -use glib::subclass::prelude::*; - +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_log, gst_trace}; diff --git a/generic/threadshare/src/inputselector/mod.rs b/generic/threadshare/src/inputselector/mod.rs index 141a32a2..13eb2c82 100644 --- a/generic/threadshare/src/inputselector/mod.rs +++ b/generic/threadshare/src/inputselector/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/generic/threadshare/src/jitterbuffer/ffi.rs b/generic/threadshare/src/jitterbuffer/ffi.rs index cc1eb41d..5175316c 100644 --- a/generic/threadshare/src/jitterbuffer/ffi.rs +++ b/generic/threadshare/src/jitterbuffer/ffi.rs @@ -16,6 +16,7 @@ // Boston, MA 02110-1335, USA. use glib::ffi::{gboolean, gpointer, GList, GType}; +use gst::glib; use gst::ffi::GstClockTime; use libc::{c_int, c_uint, c_ulonglong, c_ushort, c_void}; diff --git a/generic/threadshare/src/jitterbuffer/imp.rs b/generic/threadshare/src/jitterbuffer/imp.rs index ba0df1b1..e89d939f 100644 --- a/generic/threadshare/src/jitterbuffer/imp.rs +++ b/generic/threadshare/src/jitterbuffer/imp.rs @@ -19,9 +19,7 @@ use futures::future::BoxFuture; use futures::future::{abortable, AbortHandle, Aborted}; use futures::prelude::*; -use glib::prelude::*; -use glib::subclass::prelude::*; - +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_info, gst_log, gst_trace}; diff --git a/generic/threadshare/src/jitterbuffer/jitterbuffer.rs b/generic/threadshare/src/jitterbuffer/jitterbuffer.rs index aca555f3..67e24402 100644 --- a/generic/threadshare/src/jitterbuffer/jitterbuffer.rs +++ b/generic/threadshare/src/jitterbuffer/jitterbuffer.rs @@ -19,8 +19,9 @@ use super::ffi; use std::ptr; -use glib::prelude::*; use glib::translate::*; +use gst::glib; +use gst::prelude::*; use std::mem; diff --git a/generic/threadshare/src/jitterbuffer/mod.rs b/generic/threadshare/src/jitterbuffer/mod.rs index 693d7f4a..57904885 100644 --- a/generic/threadshare/src/jitterbuffer/mod.rs +++ b/generic/threadshare/src/jitterbuffer/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod ffi; mod imp; diff --git a/generic/threadshare/src/lib.rs b/generic/threadshare/src/lib.rs index c319f675..eab19956 100644 --- a/generic/threadshare/src/lib.rs +++ b/generic/threadshare/src/lib.rs @@ -41,6 +41,7 @@ mod proxy; mod queue; use glib::translate::*; +use gst::glib; fn plugin_init(plugin: &gst::Plugin) -> Result<(), glib::BoolError> { udpsrc::register(plugin)?; diff --git a/generic/threadshare/src/proxy/imp.rs b/generic/threadshare/src/proxy/imp.rs index 8cbd61aa..4ee74019 100644 --- a/generic/threadshare/src/proxy/imp.rs +++ b/generic/threadshare/src/proxy/imp.rs @@ -19,9 +19,7 @@ use futures::channel::oneshot; use futures::future::BoxFuture; use futures::prelude::*; -use glib::prelude::*; -use glib::subclass::prelude::*; - +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_log, gst_trace}; diff --git a/generic/threadshare/src/proxy/mod.rs b/generic/threadshare/src/proxy/mod.rs index 417267a6..4351ff7d 100644 --- a/generic/threadshare/src/proxy/mod.rs +++ b/generic/threadshare/src/proxy/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/generic/threadshare/src/queue/imp.rs b/generic/threadshare/src/queue/imp.rs index afe843a5..cc62a0fa 100644 --- a/generic/threadshare/src/queue/imp.rs +++ b/generic/threadshare/src/queue/imp.rs @@ -19,9 +19,7 @@ use futures::channel::oneshot; use futures::future::BoxFuture; use futures::prelude::*; -use glib::prelude::*; -use glib::subclass::prelude::*; - +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_log, gst_trace}; diff --git a/generic/threadshare/src/queue/mod.rs b/generic/threadshare/src/queue/mod.rs index ccf8cb40..5fc0e57c 100644 --- a/generic/threadshare/src/queue/mod.rs +++ b/generic/threadshare/src/queue/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/generic/threadshare/src/socket.rs b/generic/threadshare/src/socket.rs index 2e704674..169a62d3 100644 --- a/generic/threadshare/src/socket.rs +++ b/generic/threadshare/src/socket.rs @@ -18,6 +18,7 @@ use futures::future::BoxFuture; +use gst::glib; use gst::prelude::*; use gst::{gst_debug, gst_error, gst_log}; diff --git a/generic/threadshare/src/tcpclientsrc/imp.rs b/generic/threadshare/src/tcpclientsrc/imp.rs index a6dedd52..2d580897 100644 --- a/generic/threadshare/src/tcpclientsrc/imp.rs +++ b/generic/threadshare/src/tcpclientsrc/imp.rs @@ -20,9 +20,7 @@ use futures::future::BoxFuture; use futures::lock::Mutex as FutMutex; use futures::prelude::*; -use glib::prelude::*; -use glib::subclass::prelude::*; - +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_log, gst_trace}; diff --git a/generic/threadshare/src/tcpclientsrc/mod.rs b/generic/threadshare/src/tcpclientsrc/mod.rs index e34cd4e2..7e8d12aa 100644 --- a/generic/threadshare/src/tcpclientsrc/mod.rs +++ b/generic/threadshare/src/tcpclientsrc/mod.rs @@ -16,7 +16,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/generic/threadshare/src/udpsink/imp.rs b/generic/threadshare/src/udpsink/imp.rs index fc5c8917..2a6f96b7 100644 --- a/generic/threadshare/src/udpsink/imp.rs +++ b/generic/threadshare/src/udpsink/imp.rs @@ -20,9 +20,7 @@ use futures::future::BoxFuture; use futures::lock::Mutex; use futures::prelude::*; -use glib::prelude::*; -use glib::subclass::prelude::*; - +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::EventView; diff --git a/generic/threadshare/src/udpsink/mod.rs b/generic/threadshare/src/udpsink/mod.rs index 1776694a..ceff6b02 100644 --- a/generic/threadshare/src/udpsink/mod.rs +++ b/generic/threadshare/src/udpsink/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/generic/threadshare/src/udpsrc/imp.rs b/generic/threadshare/src/udpsrc/imp.rs index d0b9dcfc..347cc444 100644 --- a/generic/threadshare/src/udpsrc/imp.rs +++ b/generic/threadshare/src/udpsrc/imp.rs @@ -19,9 +19,7 @@ use futures::future::BoxFuture; use futures::lock::Mutex as FutMutex; use futures::prelude::*; -use glib::prelude::*; -use glib::subclass::prelude::*; - +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_log, gst_trace}; diff --git a/generic/threadshare/src/udpsrc/mod.rs b/generic/threadshare/src/udpsrc/mod.rs index 37ffb0d1..cdb7c3d2 100644 --- a/generic/threadshare/src/udpsrc/mod.rs +++ b/generic/threadshare/src/udpsrc/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/generic/threadshare/tests/appsrc.rs b/generic/threadshare/tests/appsrc.rs index a6712b68..387c9e75 100644 --- a/generic/threadshare/tests/appsrc.rs +++ b/generic/threadshare/tests/appsrc.rs @@ -15,7 +15,6 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; use gst::prelude::*; fn init() { diff --git a/generic/threadshare/tests/inputselector.rs b/generic/threadshare/tests/inputselector.rs index 90a7ceb4..7f7dc826 100644 --- a/generic/threadshare/tests/inputselector.rs +++ b/generic/threadshare/tests/inputselector.rs @@ -15,7 +15,6 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; use gst::prelude::*; fn init() { diff --git a/generic/threadshare/tests/pad.rs b/generic/threadshare/tests/pad.rs index f23a5f9d..686a6f48 100644 --- a/generic/threadshare/tests/pad.rs +++ b/generic/threadshare/tests/pad.rs @@ -22,6 +22,7 @@ use futures::lock::Mutex as FutMutex; use futures::prelude::*; use glib::GBoxed; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; diff --git a/generic/threadshare/tests/pipeline.rs b/generic/threadshare/tests/pipeline.rs index 30b91520..321da139 100644 --- a/generic/threadshare/tests/pipeline.rs +++ b/generic/threadshare/tests/pipeline.rs @@ -15,6 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. +use gst::glib; use gst::prelude::*; use gst::{gst_debug, gst_error}; diff --git a/generic/threadshare/tests/proxy.rs b/generic/threadshare/tests/proxy.rs index 319e812e..5c2b28df 100644 --- a/generic/threadshare/tests/proxy.rs +++ b/generic/threadshare/tests/proxy.rs @@ -15,7 +15,6 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; use gst::prelude::*; use std::sync::{Arc, Mutex}; diff --git a/generic/threadshare/tests/queue.rs b/generic/threadshare/tests/queue.rs index bf0ce17b..f107ff50 100644 --- a/generic/threadshare/tests/queue.rs +++ b/generic/threadshare/tests/queue.rs @@ -15,7 +15,6 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; use gst::prelude::*; use std::sync::{Arc, Mutex}; diff --git a/generic/threadshare/tests/tcpclientsrc.rs b/generic/threadshare/tests/tcpclientsrc.rs index 55f2df1d..c60417bf 100644 --- a/generic/threadshare/tests/tcpclientsrc.rs +++ b/generic/threadshare/tests/tcpclientsrc.rs @@ -16,7 +16,6 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; use gst::prelude::*; use std::io::Write; diff --git a/generic/threadshare/tests/udpsink.rs b/generic/threadshare/tests/udpsink.rs index b5670a41..4590ceef 100644 --- a/generic/threadshare/tests/udpsink.rs +++ b/generic/threadshare/tests/udpsink.rs @@ -17,7 +17,7 @@ use std::thread; -use glib::prelude::*; +use gst::prelude::*; fn init() { use std::sync::Once; diff --git a/generic/threadshare/tests/udpsrc.rs b/generic/threadshare/tests/udpsrc.rs index 5eac5754..095c89c7 100644 --- a/generic/threadshare/tests/udpsrc.rs +++ b/generic/threadshare/tests/udpsrc.rs @@ -15,7 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::prelude::*; use std::thread; diff --git a/net/reqwest/Cargo.toml b/net/reqwest/Cargo.toml index 65a8d2d7..7ac9f314 100644 --- a/net/reqwest/Cargo.toml +++ b/net/reqwest/Cargo.toml @@ -9,7 +9,6 @@ edition = "2018" [dependencies] url = "2.1" -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } reqwest = { version = "0.11", features = ["cookies", "gzip"] } futures = "0.3" hyperx = "1.0" diff --git a/net/reqwest/src/lib.rs b/net/reqwest/src/lib.rs index a43041d6..915c62ea 100644 --- a/net/reqwest/src/lib.rs +++ b/net/reqwest/src/lib.rs @@ -6,6 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. +use gst::glib; + mod reqwesthttpsrc; fn plugin_init(plugin: &gst::Plugin) -> Result<(), glib::BoolError> { diff --git a/net/reqwest/src/reqwesthttpsrc/imp.rs b/net/reqwest/src/reqwesthttpsrc/imp.rs index 46e3aeef..0b46ccd7 100644 --- a/net/reqwest/src/reqwesthttpsrc/imp.rs +++ b/net/reqwest/src/reqwesthttpsrc/imp.rs @@ -17,7 +17,7 @@ use url::Url; use once_cell::sync::Lazy; -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_trace, gst_warning}; diff --git a/net/reqwest/src/reqwesthttpsrc/mod.rs b/net/reqwest/src/reqwesthttpsrc/mod.rs index 9f5c35c8..be4fd1dd 100644 --- a/net/reqwest/src/reqwesthttpsrc/mod.rs +++ b/net/reqwest/src/reqwesthttpsrc/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/net/reqwest/tests/reqwesthttpsrc.rs b/net/reqwest/tests/reqwesthttpsrc.rs index 6eb7c9e0..e30323d2 100644 --- a/net/reqwest/tests/reqwesthttpsrc.rs +++ b/net/reqwest/tests/reqwesthttpsrc.rs @@ -6,6 +6,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. +use gst::glib; use gst::prelude::*; use std::sync::mpsc; diff --git a/net/rusoto/Cargo.toml b/net/rusoto/Cargo.toml index ad3163d1..d8176ab7 100644 --- a/net/rusoto/Cargo.toml +++ b/net/rusoto/Cargo.toml @@ -12,7 +12,6 @@ edition = "2018" [dependencies] bytes = "1.0" futures = "0.3" -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } gst = { package = "gstreamer", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs", features = ["v1_12"] } gst-base = { package = "gstreamer-base", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs", features = ["v1_12"] } rusoto_core = "0.46" diff --git a/net/rusoto/src/aws_transcriber/imp.rs b/net/rusoto/src/aws_transcriber/imp.rs index 5ef5c856..ba548246 100644 --- a/net/rusoto/src/aws_transcriber/imp.rs +++ b/net/rusoto/src/aws_transcriber/imp.rs @@ -15,8 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{ diff --git a/net/rusoto/src/aws_transcriber/mod.rs b/net/rusoto/src/aws_transcriber/mod.rs index 20ddb1eb..b4fdf270 100644 --- a/net/rusoto/src/aws_transcriber/mod.rs +++ b/net/rusoto/src/aws_transcriber/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; mod packet; diff --git a/net/rusoto/src/lib.rs b/net/rusoto/src/lib.rs index 46fff023..91f11bb0 100644 --- a/net/rusoto/src/lib.rs +++ b/net/rusoto/src/lib.rs @@ -6,6 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. +use gst::glib; + mod aws_transcriber; mod s3sink; mod s3src; diff --git a/net/rusoto/src/s3sink/imp.rs b/net/rusoto/src/s3sink/imp.rs index c02e91f5..6ee2550c 100644 --- a/net/rusoto/src/s3sink/imp.rs +++ b/net/rusoto/src/s3sink/imp.rs @@ -6,9 +6,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; -use glib::subclass::prelude::*; - +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_error, gst_info, gst_trace}; diff --git a/net/rusoto/src/s3sink/mod.rs b/net/rusoto/src/s3sink/mod.rs index a9c96bcd..57dc6a1d 100644 --- a/net/rusoto/src/s3sink/mod.rs +++ b/net/rusoto/src/s3sink/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/net/rusoto/src/s3src/imp.rs b/net/rusoto/src/s3src/imp.rs index 07cb4ab0..53b2bc3b 100644 --- a/net/rusoto/src/s3src/imp.rs +++ b/net/rusoto/src/s3src/imp.rs @@ -13,9 +13,8 @@ use futures::future; use once_cell::sync::Lazy; use rusoto_s3::*; -use glib::prelude::*; -use glib::subclass::prelude::*; - +use gst::glib; +use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_info}; diff --git a/net/rusoto/src/s3src/mod.rs b/net/rusoto/src/s3src/mod.rs index 941738ac..2d22df23 100644 --- a/net/rusoto/src/s3src/mod.rs +++ b/net/rusoto/src/s3src/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/text/json/Cargo.toml b/text/json/Cargo.toml index 59b7641c..14a60618 100644 --- a/text/json/Cargo.toml +++ b/text/json/Cargo.toml @@ -8,7 +8,6 @@ description = "Rust JSON Plugin" repository = "https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs" [dependencies] -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } once_cell = "1.0" serde = { version = "1.0", features = ["derive"] } serde_json = { version = "1.0", features = ["raw_value"] } diff --git a/text/json/src/jsongstenc/imp.rs b/text/json/src/jsongstenc/imp.rs index 090dabf8..e427f631 100644 --- a/text/json/src/jsongstenc/imp.rs +++ b/text/json/src/jsongstenc/imp.rs @@ -15,7 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_log, gst_trace}; diff --git a/text/json/src/jsongstenc/mod.rs b/text/json/src/jsongstenc/mod.rs index b3fdb56b..81a9aa15 100644 --- a/text/json/src/jsongstenc/mod.rs +++ b/text/json/src/jsongstenc/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/text/json/src/jsongstparse/imp.rs b/text/json/src/jsongstparse/imp.rs index 02f93683..cbb22481 100644 --- a/text/json/src/jsongstparse/imp.rs +++ b/text/json/src/jsongstparse/imp.rs @@ -15,8 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_info, gst_log, gst_trace, gst_warning}; diff --git a/text/json/src/jsongstparse/mod.rs b/text/json/src/jsongstparse/mod.rs index cc7eeda3..b40996d7 100644 --- a/text/json/src/jsongstparse/mod.rs +++ b/text/json/src/jsongstparse/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/text/json/src/lib.rs b/text/json/src/lib.rs index 4d910698..2187b236 100644 --- a/text/json/src/lib.rs +++ b/text/json/src/lib.rs @@ -17,6 +17,8 @@ #![recursion_limit = "128"] +use gst::glib; + mod jsongstenc; mod jsongstparse; mod line_reader; diff --git a/text/regex/Cargo.toml b/text/regex/Cargo.toml index 563c7d95..ce2e7414 100644 --- a/text/regex/Cargo.toml +++ b/text/regex/Cargo.toml @@ -8,7 +8,6 @@ description = "Rust Regular Expression Plugin" repository = "https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs" [dependencies] -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } once_cell = "1.0" regex = "1" diff --git a/text/regex/src/gstregex/imp.rs b/text/regex/src/gstregex/imp.rs index 99f50c37..88e45b3d 100644 --- a/text/regex/src/gstregex/imp.rs +++ b/text/regex/src/gstregex/imp.rs @@ -15,8 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; -use glib::subclass::prelude::*; +use gst::glib; use gst::gst_error; use gst::prelude::*; use gst::subclass::prelude::*; diff --git a/text/regex/src/gstregex/mod.rs b/text/regex/src/gstregex/mod.rs index 45355aa1..6884bb30 100644 --- a/text/regex/src/gstregex/mod.rs +++ b/text/regex/src/gstregex/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/text/regex/src/lib.rs b/text/regex/src/lib.rs index 7389d8a3..ae781132 100644 --- a/text/regex/src/lib.rs +++ b/text/regex/src/lib.rs @@ -17,6 +17,8 @@ #![recursion_limit = "128"] +use gst::glib; + mod gstregex; fn plugin_init(plugin: &gst::Plugin) -> Result<(), glib::BoolError> { diff --git a/text/regex/tests/regex.rs b/text/regex/tests/regex.rs index 273dbdf4..4826f06d 100644 --- a/text/regex/tests/regex.rs +++ b/text/regex/tests/regex.rs @@ -15,7 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::prelude::*; fn init() { use std::sync::Once; diff --git a/text/wrap/Cargo.toml b/text/wrap/Cargo.toml index 07f523cf..4c8831fe 100644 --- a/text/wrap/Cargo.toml +++ b/text/wrap/Cargo.toml @@ -8,7 +8,6 @@ description = "Rust Text Wrap Plugin" repository = "https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs" [dependencies] -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } once_cell = "1.0" textwrap = { version = "0.13.2", features = ["hyphenation"] } hyphenation = "0.8" diff --git a/text/wrap/src/gsttextwrap/imp.rs b/text/wrap/src/gsttextwrap/imp.rs index 34361497..861c2d5c 100644 --- a/text/wrap/src/gsttextwrap/imp.rs +++ b/text/wrap/src/gsttextwrap/imp.rs @@ -15,8 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_info, gst_log}; diff --git a/text/wrap/src/gsttextwrap/mod.rs b/text/wrap/src/gsttextwrap/mod.rs index 6b5acef2..5d9554f5 100644 --- a/text/wrap/src/gsttextwrap/mod.rs +++ b/text/wrap/src/gsttextwrap/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/text/wrap/src/lib.rs b/text/wrap/src/lib.rs index c9cf7863..3dc8b201 100644 --- a/text/wrap/src/lib.rs +++ b/text/wrap/src/lib.rs @@ -17,6 +17,8 @@ #![recursion_limit = "128"] +use gst::glib; + mod gsttextwrap; fn plugin_init(plugin: &gst::Plugin) -> Result<(), glib::BoolError> { diff --git a/text/wrap/tests/textwrap.rs b/text/wrap/tests/textwrap.rs index f346e736..74c18d6f 100644 --- a/text/wrap/tests/textwrap.rs +++ b/text/wrap/tests/textwrap.rs @@ -15,7 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::prelude::*; fn init() { use std::sync::Once; diff --git a/tutorial/Cargo.toml b/tutorial/Cargo.toml index 63dde729..551db4cb 100644 --- a/tutorial/Cargo.toml +++ b/tutorial/Cargo.toml @@ -8,7 +8,6 @@ edition = "2018" description = "Rust Tutorial Plugin" [dependencies] -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } gst = { package = "gstreamer", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gst-base = { package = "gstreamer-base", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gst-video = { package = "gstreamer-video", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } diff --git a/tutorial/src/identity/imp.rs b/tutorial/src/identity/imp.rs index 6b56e1b5..6f12f678 100644 --- a/tutorial/src/identity/imp.rs +++ b/tutorial/src/identity/imp.rs @@ -6,7 +6,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_log, gst_trace}; diff --git a/tutorial/src/identity/mod.rs b/tutorial/src/identity/mod.rs index d7d45183..15d18158 100644 --- a/tutorial/src/identity/mod.rs +++ b/tutorial/src/identity/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/tutorial/src/lib.rs b/tutorial/src/lib.rs index f1ce2dd2..bb3ff865 100644 --- a/tutorial/src/lib.rs +++ b/tutorial/src/lib.rs @@ -6,6 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. +use gst::glib; + mod identity; mod progressbin; mod rgb2gray; diff --git a/tutorial/src/progressbin/imp.rs b/tutorial/src/progressbin/imp.rs index 94a3909f..47bab498 100644 --- a/tutorial/src/progressbin/imp.rs +++ b/tutorial/src/progressbin/imp.rs @@ -6,8 +6,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; -use glib::subclass::prelude::*; +use gst::glib; use gst::gst_info; use gst::prelude::*; use gst::subclass::prelude::*; diff --git a/tutorial/src/progressbin/mod.rs b/tutorial/src/progressbin/mod.rs index d4f940f7..0e38f75a 100644 --- a/tutorial/src/progressbin/mod.rs +++ b/tutorial/src/progressbin/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/tutorial/src/rgb2gray/imp.rs b/tutorial/src/rgb2gray/imp.rs index ef76f866..3f5e724d 100644 --- a/tutorial/src/rgb2gray/imp.rs +++ b/tutorial/src/rgb2gray/imp.rs @@ -6,7 +6,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_info}; diff --git a/tutorial/src/rgb2gray/mod.rs b/tutorial/src/rgb2gray/mod.rs index 988904d7..28faa28d 100644 --- a/tutorial/src/rgb2gray/mod.rs +++ b/tutorial/src/rgb2gray/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/tutorial/src/sinesrc/imp.rs b/tutorial/src/sinesrc/imp.rs index 7195e550..b3556a24 100644 --- a/tutorial/src/sinesrc/imp.rs +++ b/tutorial/src/sinesrc/imp.rs @@ -6,7 +6,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_info, gst_log}; diff --git a/tutorial/src/sinesrc/mod.rs b/tutorial/src/sinesrc/mod.rs index 8e396499..7342f268 100644 --- a/tutorial/src/sinesrc/mod.rs +++ b/tutorial/src/sinesrc/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/tutorial/tutorial-1.md b/tutorial/tutorial-1.md index 68d95ec1..2e2c3ec0 100644 --- a/tutorial/tutorial-1.md +++ b/tutorial/tutorial-1.md @@ -10,18 +10,17 @@ The final code for this plugin can be found [here](https://gitlab.freedesktop.or # Table of contents -1. [Project Structure](#project-structure) -1. [Plugin Initialization](#plugin-initialization) -1. [Type Registration](#type-registration) -1. [Type Class and Instance Initialization](#type-class-and-instance-initialization) -1. [Caps and Pad Templates](#caps-and-pad-templates) -1. [Caps Handling Part 1](#caps-handling-part-1) -1. [Caps Handling Part 2](#caps-handling-part-2) -1. [Conversion of BGRx Video Frames to Grayscale](#conversion-of-bgrx-video-frames-to-grayscale) -1. [Testing the new element](#testing-the-new-element) -1. [Properties](#properties) -1. [What next](#what-next) - + 1. [Project Structure](#project-structure) + 2. [Plugin Initialization](#plugin-initialization) + 3. [Type Registration](#type-registration) + 4. [Type Class and Instance Initialization](#type-class-and-instance-initialization) + 5. [Caps and Pad Templates](#caps-and-pad-templates) + 6. [Caps Handling Part 1](#caps-handling-part-1) + 7. [Caps Handling Part 2](#caps-handling-part-2) + 8. [Conversion of BGRx Video Frames to Grayscale](#conversion-of-bgrx-video-frames-to-grayscale) + 9. [Testing the new element](#testing-the-new-element) + 10. [Properties](#properties) + 11. [What next](#what-next) ## Project Structure @@ -41,7 +40,6 @@ edition = "2018" description = "Rust Tutorial Plugin" [dependencies] -glib = { git = "https://github.com/gtk-rs/glib" } gst = { package = "gstreamer", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gst-base = { package = "gstreamer-base", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gst-video = { package = "gstreamer-video", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } @@ -91,15 +89,16 @@ gst::plugin_define!( GStreamer requires this information to be statically available in the shared library, not returned by a function. The static plugin metadata that we provide here is -1. name of the plugin -1. short description for the plugin -1. name of the plugin entry point function -1. version number of the plugin -1. license of the plugin (only a fixed set of licenses is allowed here, [see](https://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPlugin.html#GstPluginDesc)) -1. source package name -1. binary package name (only really makes sense for e.g. Linux distributions) -1. origin of the plugin -1. release date of this version + + 1. name of the plugin + 1. short description for the plugin + 1. name of the plugin entry point function + 1. version number of the plugin + 1. license of the plugin (only a fixed set of licenses is allowed here, [see](https://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPlugin.html#GstPluginDesc)) + 1. source package name + 1. binary package name (only really makes sense for e.g. Linux distributions) + 1. origin of the plugin + 1. release date of this version Next we create `build.rs` in the project main directory. @@ -133,6 +132,8 @@ gst-inspect-1.0 target/debug/libgstrstutorial.so As a next step, we’re going to add another module `rgb2gray` to our project, and call a function called `register` from our `plugin_init` function. ```rust +use gst::glib; + mod rgb2gray; fn plugin_init(plugin: &gst::Plugin) -> Result<(), glib::BoolError> { @@ -144,11 +145,7 @@ fn plugin_init(plugin: &gst::Plugin) -> Result<(), glib::BoolError> { With that our `src/lib.rs` is complete, and all following code is only in `src/rgb2gray/imp.rs`. At the top of the new file we first need to add various `use-directives` to import various types, macros and functions we’re going to use into the current module’s scope. ```rust -use glib::subclass; -use glib::subclass::prelude::*; - -use gst::prelude::*; -use gst::subclass::prelude::*; +use gst::glib; use gst::{gst_debug, gst_info}; use gst_base::subclass::prelude::*; @@ -163,6 +160,8 @@ GStreamer is based on the GLib object system ([GObject](https://developer.gnome. So, as a next step we need to register a new type for our RGB to Grayscale converter GStreamer element with the GObject type system, and then register that type with GStreamer to be able to create new instances of it. We do this with the following code ```rust +use gst::glib; + #[derive(Default)] pub struct Rgb2Gray {} @@ -183,11 +182,11 @@ This defines a struct `Rgb2Gray` which is empty for now and an empty implementat We also add the following code is in `src/rgb2gray/mod.rs`: ```rust -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; -// The public Rust wrapper type for our element glib::wrapper! { pub struct Rgb2Gray(ObjectSubclass) @extends gst_base::BaseTransform, gst::Element, gst::Object; } @@ -220,6 +219,8 @@ In addition, we also define a `register` function (the one that is already calle As a next step we implement the `new` funtion and `class_init` functions. In the first version, this struct is empty for now but we will later use it to store all state of our element. ```rust +use gst::glib; + #[derive(Default)] pub struct Rgb2Gray {} @@ -286,10 +287,12 @@ impl BaseTransformImpl for Rgb2Gray {} ``` ```rust -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; +// The public Rust wrapper type for our element glib::wrapper! { pub struct Rgb2Gray(ObjectSubclass) @extends gst_base::BaseTransform, gst::Element, gst::Object; } diff --git a/tutorial/tutorial-2.md b/tutorial/tutorial-2.md index dfa0e56b..cc3afac3 100644 --- a/tutorial/tutorial-2.md +++ b/tutorial/tutorial-2.md @@ -4,12 +4,12 @@ In this part, a raw audio sine wave source element is going to be written. The f ### Table of Contents -1. [Boilerplate](#boilerplate) -2. [Caps Negotiation](#caps-negotiation) -3. [Buffer Creation](#buffer-creation) -4. [(Pseudo) Live Mode](#pseudo-live-mode) -5. [Unlocking](#unlocking) -6. [Seeking](#seeking) + 1. [Boilerplate](#boilerplate) + 2. [Caps Negotiation](#caps-negotiation) + 3. [Buffer Creation](#buffer-creation) + 4. [(Pseudo) Live Mode](#pseudo-live-mode) + 5. [Unlocking](#unlocking) + 6. [Seeking](#seeking) ### Boilerplate @@ -22,8 +22,7 @@ So let's get started with all the boilerplate. This time our element will be bas In `src/sinesrc/imp.rs`: ```rust -use glib::prelude::*; -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_info, gst_log}; @@ -366,7 +365,8 @@ impl BaseSrcImpl for SineSrc { In `src/sinesrc/mod.rs`: ```rust -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/utils/fallbackswitch/Cargo.toml b/utils/fallbackswitch/Cargo.toml index 219fbd9a..36fa114b 100644 --- a/utils/fallbackswitch/Cargo.toml +++ b/utils/fallbackswitch/Cargo.toml @@ -9,7 +9,6 @@ description = "Fallback Switcher Plugin" [dependencies] libc = { version = "0.2", optional = true } -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } gst = { package = "gstreamer", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs", features = ["v1_14"] } gst-base = { package = "gstreamer-base", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs", features = ["v1_16"] } gst-audio = { package = "gstreamer-audio", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs", features = ["v1_14"] } diff --git a/utils/fallbackswitch/examples/gtk_fallbackswitch.rs b/utils/fallbackswitch/examples/gtk_fallbackswitch.rs index c86cdbfa..bf781b6b 100644 --- a/utils/fallbackswitch/examples/gtk_fallbackswitch.rs +++ b/utils/fallbackswitch/examples/gtk_fallbackswitch.rs @@ -17,6 +17,7 @@ use gio::prelude::*; +use gst::glib; use gst::prelude::*; use gtk::prelude::*; diff --git a/utils/fallbackswitch/src/base/aggregator.rs b/utils/fallbackswitch/src/base/aggregator.rs index 78d79411..5b057903 100644 --- a/utils/fallbackswitch/src/base/aggregator.rs +++ b/utils/fallbackswitch/src/base/aggregator.rs @@ -8,11 +8,12 @@ use super::ffi; use super::Aggregator; -use glib::prelude::*; use glib::signal::{connect_raw, SignalHandlerId}; use glib::translate::*; use glib::IsA; use glib::Value; +use gst::glib; +use gst::prelude::*; use std::boxed::Box as Box_; use std::mem; use std::ptr; diff --git a/utils/fallbackswitch/src/base/aggregator_pad.rs b/utils/fallbackswitch/src/base/aggregator_pad.rs index ecdbd4d0..a9ca17c9 100644 --- a/utils/fallbackswitch/src/base/aggregator_pad.rs +++ b/utils/fallbackswitch/src/base/aggregator_pad.rs @@ -10,6 +10,7 @@ use super::ffi; use super::AggregatorPad; use glib::object::IsA; use glib::translate::*; +use gst::glib; pub trait AggregatorPadExtManual: 'static { fn segment(&self) -> gst::Segment; diff --git a/utils/fallbackswitch/src/base/auto/aggregator.rs b/utils/fallbackswitch/src/base/auto/aggregator.rs index 8c570ec0..66f6b9ad 100644 --- a/utils/fallbackswitch/src/base/auto/aggregator.rs +++ b/utils/fallbackswitch/src/base/auto/aggregator.rs @@ -10,6 +10,7 @@ use glib::signal::connect_raw; use glib::signal::SignalHandlerId; use glib::translate::*; use glib::StaticType; +use gst::glib; use std::boxed::Box as Box_; use std::mem::transmute; diff --git a/utils/fallbackswitch/src/base/auto/aggregator_pad.rs b/utils/fallbackswitch/src/base/auto/aggregator_pad.rs index b9c3c92f..fe7204de 100644 --- a/utils/fallbackswitch/src/base/auto/aggregator_pad.rs +++ b/utils/fallbackswitch/src/base/auto/aggregator_pad.rs @@ -9,6 +9,7 @@ use glib::signal::connect_raw; use glib::signal::SignalHandlerId; use glib::translate::*; use glib::StaticType; +use gst::glib; use std::boxed::Box as Box_; use std::mem::transmute; diff --git a/utils/fallbackswitch/src/base/ffi.rs b/utils/fallbackswitch/src/base/ffi.rs index 94bf75e1..e4004f55 100644 --- a/utils/fallbackswitch/src/base/ffi.rs +++ b/utils/fallbackswitch/src/base/ffi.rs @@ -14,7 +14,7 @@ use libc::{ }; #[allow(unused_imports)] -use glib::ffi::{gboolean, gconstpointer, gpointer, GType}; +use ::gst::glib::ffi::{gboolean, gconstpointer, gpointer, GType}; #[repr(C)] #[derive(Copy, Clone)] diff --git a/utils/fallbackswitch/src/base/mod.rs b/utils/fallbackswitch/src/base/mod.rs index ef0e352d..62481954 100644 --- a/utils/fallbackswitch/src/base/mod.rs +++ b/utils/fallbackswitch/src/base/mod.rs @@ -11,7 +11,7 @@ mod aggregator; mod aggregator_pad; pub mod prelude { - pub use glib::prelude::*; + pub use gst::glib::prelude::*; pub use gst::prelude::*; pub use super::aggregator::AggregatorExtManual; diff --git a/utils/fallbackswitch/src/base/subclass/aggregator.rs b/utils/fallbackswitch/src/base/subclass/aggregator.rs index 8196b81d..8d694fb0 100644 --- a/utils/fallbackswitch/src/base/subclass/aggregator.rs +++ b/utils/fallbackswitch/src/base/subclass/aggregator.rs @@ -8,10 +8,9 @@ use super::super::ffi; -use glib::prelude::*; -use glib::subclass::prelude::*; use glib::translate::*; - +use gst::glib; +use gst::prelude::*; use gst::subclass::prelude::*; use std::ptr; diff --git a/utils/fallbackswitch/src/base/subclass/aggregator_pad.rs b/utils/fallbackswitch/src/base/subclass/aggregator_pad.rs index 6a8c67bb..3fb48710 100644 --- a/utils/fallbackswitch/src/base/subclass/aggregator_pad.rs +++ b/utils/fallbackswitch/src/base/subclass/aggregator_pad.rs @@ -8,9 +8,9 @@ use super::super::ffi; -use glib::prelude::*; -use glib::subclass::prelude::*; use glib::translate::*; +use gst::glib; +use gst::prelude::*; use gst::subclass::prelude::*; diff --git a/utils/fallbackswitch/src/base/utils.rs b/utils/fallbackswitch/src/base/utils.rs index 2dc756e6..d6b33da9 100644 --- a/utils/fallbackswitch/src/base/utils.rs +++ b/utils/fallbackswitch/src/base/utils.rs @@ -7,6 +7,7 @@ // except according to those terms. use glib::translate::mut_override; +use gst::glib; #[must_use = "if unused the Mutex will immediately unlock"] pub struct MutexGuard<'a>(&'a glib::ffi::GMutex); diff --git a/utils/fallbackswitch/src/fallbacksrc/custom_source/imp.rs b/utils/fallbackswitch/src/fallbacksrc/custom_source/imp.rs index 688187d7..8b4c49ba 100644 --- a/utils/fallbackswitch/src/fallbacksrc/custom_source/imp.rs +++ b/utils/fallbackswitch/src/fallbacksrc/custom_source/imp.rs @@ -15,8 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error}; diff --git a/utils/fallbackswitch/src/fallbacksrc/custom_source/mod.rs b/utils/fallbackswitch/src/fallbacksrc/custom_source/mod.rs index a43c263c..b3a958e2 100644 --- a/utils/fallbackswitch/src/fallbacksrc/custom_source/mod.rs +++ b/utils/fallbackswitch/src/fallbacksrc/custom_source/mod.rs @@ -15,6 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. +use gst::glib; + mod imp; glib::wrapper! { diff --git a/utils/fallbackswitch/src/fallbacksrc/imp.rs b/utils/fallbackswitch/src/fallbacksrc/imp.rs index bd48b16c..8cf51415 100644 --- a/utils/fallbackswitch/src/fallbacksrc/imp.rs +++ b/utils/fallbackswitch/src/fallbacksrc/imp.rs @@ -15,8 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_info, gst_warning}; diff --git a/utils/fallbackswitch/src/fallbacksrc/mod.rs b/utils/fallbackswitch/src/fallbacksrc/mod.rs index 1d155911..33a66ba3 100644 --- a/utils/fallbackswitch/src/fallbacksrc/mod.rs +++ b/utils/fallbackswitch/src/fallbacksrc/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod custom_source; mod imp; diff --git a/utils/fallbackswitch/src/fallbacksrc/video_fallback/imp.rs b/utils/fallbackswitch/src/fallbacksrc/video_fallback/imp.rs index c51ed9ca..1221fa3a 100644 --- a/utils/fallbackswitch/src/fallbacksrc/video_fallback/imp.rs +++ b/utils/fallbackswitch/src/fallbacksrc/video_fallback/imp.rs @@ -16,8 +16,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_info, gst_warning}; diff --git a/utils/fallbackswitch/src/fallbacksrc/video_fallback/mod.rs b/utils/fallbackswitch/src/fallbacksrc/video_fallback/mod.rs index 2577d7b5..db51a3ea 100644 --- a/utils/fallbackswitch/src/fallbacksrc/video_fallback/mod.rs +++ b/utils/fallbackswitch/src/fallbacksrc/video_fallback/mod.rs @@ -16,6 +16,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. +use gst::glib; + mod imp; glib::wrapper! { diff --git a/utils/fallbackswitch/src/fallbackswitch/imp.rs b/utils/fallbackswitch/src/fallbackswitch/imp.rs index 0c856a97..94b09f75 100644 --- a/utils/fallbackswitch/src/fallbackswitch/imp.rs +++ b/utils/fallbackswitch/src/fallbackswitch/imp.rs @@ -15,6 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. +use gst::glib; + #[cfg(not(feature = "v1_18"))] use self::gst_base::prelude::*; #[cfg(not(feature = "v1_18"))] diff --git a/utils/fallbackswitch/src/fallbackswitch/mod.rs b/utils/fallbackswitch/src/fallbackswitch/mod.rs index e44e48a3..0042e10b 100644 --- a/utils/fallbackswitch/src/fallbackswitch/mod.rs +++ b/utils/fallbackswitch/src/fallbackswitch/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; #[cfg(not(feature = "v1_18"))] use crate::gst_base_compat as gst_base; diff --git a/utils/fallbackswitch/src/lib.rs b/utils/fallbackswitch/src/lib.rs index aefe6853..01174737 100644 --- a/utils/fallbackswitch/src/lib.rs +++ b/utils/fallbackswitch/src/lib.rs @@ -15,6 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. +use gst::glib; + #[cfg(not(feature = "v1_18"))] #[path = "base/mod.rs"] pub mod gst_base_compat; diff --git a/utils/fallbackswitch/tests/fallbackswitch.rs b/utils/fallbackswitch/tests/fallbackswitch.rs index ca0092f1..3d9d7580 100644 --- a/utils/fallbackswitch/tests/fallbackswitch.rs +++ b/utils/fallbackswitch/tests/fallbackswitch.rs @@ -15,7 +15,6 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; use gst::gst_debug; use gst::prelude::*; diff --git a/utils/togglerecord/Cargo.toml b/utils/togglerecord/Cargo.toml index 60220119..8adb3553 100644 --- a/utils/togglerecord/Cargo.toml +++ b/utils/togglerecord/Cargo.toml @@ -8,7 +8,6 @@ repository = "https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs" edition = "2018" [dependencies] -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } gst = { package = "gstreamer", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gst-audio = { package = "gstreamer-audio", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gst-video = { package = "gstreamer-video", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } diff --git a/utils/togglerecord/examples/gtk_recording.rs b/utils/togglerecord/examples/gtk_recording.rs index d3eef9a5..ee7fc076 100644 --- a/utils/togglerecord/examples/gtk_recording.rs +++ b/utils/togglerecord/examples/gtk_recording.rs @@ -15,6 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. +use gst::glib; use gst::prelude::*; use gio::prelude::*; diff --git a/utils/togglerecord/src/lib.rs b/utils/togglerecord/src/lib.rs index 05bb34c1..ef20fe77 100644 --- a/utils/togglerecord/src/lib.rs +++ b/utils/togglerecord/src/lib.rs @@ -15,6 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. +use gst::glib; + mod togglerecord; fn plugin_init(plugin: &gst::Plugin) -> Result<(), glib::BoolError> { diff --git a/utils/togglerecord/src/togglerecord/imp.rs b/utils/togglerecord/src/togglerecord/imp.rs index b916fbe4..1ba79102 100644 --- a/utils/togglerecord/src/togglerecord/imp.rs +++ b/utils/togglerecord/src/togglerecord/imp.rs @@ -15,8 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_log, gst_trace, gst_warning}; diff --git a/utils/togglerecord/src/togglerecord/mod.rs b/utils/togglerecord/src/togglerecord/mod.rs index 382aa04e..1c0fa638 100644 --- a/utils/togglerecord/src/togglerecord/mod.rs +++ b/utils/togglerecord/src/togglerecord/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/utils/togglerecord/tests/tests.rs b/utils/togglerecord/tests/tests.rs index 6c96cb28..98db0554 100644 --- a/utils/togglerecord/tests/tests.rs +++ b/utils/togglerecord/tests/tests.rs @@ -15,8 +15,6 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; - use gst::prelude::*; use either::*; diff --git a/video/cdg/Cargo.toml b/video/cdg/Cargo.toml index 9046b83f..0b0fe9ce 100644 --- a/video/cdg/Cargo.toml +++ b/video/cdg/Cargo.toml @@ -8,7 +8,6 @@ description = "CDG Plugin" edition = "2018" [dependencies] -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } gst = { package = "gstreamer", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs", features = ["v1_12"] } gst-base = { package = "gstreamer-base", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs", features = ["v1_12"] } gst-video = { package = "gstreamer-video", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs", features = ["v1_12"] } diff --git a/video/cdg/src/cdgdec/imp.rs b/video/cdg/src/cdgdec/imp.rs index 2d2c6cd2..678af14b 100644 --- a/video/cdg/src/cdgdec/imp.rs +++ b/video/cdg/src/cdgdec/imp.rs @@ -6,7 +6,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::subclass::prelude::*; +use gst::glib; use gst::gst_debug; use gst::subclass::prelude::*; use gst_video::prelude::*; diff --git a/video/cdg/src/cdgdec/mod.rs b/video/cdg/src/cdgdec/mod.rs index 6e2e4e37..a942b8d9 100644 --- a/video/cdg/src/cdgdec/mod.rs +++ b/video/cdg/src/cdgdec/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/video/cdg/src/cdgparse/imp.rs b/video/cdg/src/cdgparse/imp.rs index 8f7dde79..c89ab323 100644 --- a/video/cdg/src/cdgparse/imp.rs +++ b/video/cdg/src/cdgparse/imp.rs @@ -6,8 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::subclass::prelude::*; use gst::format::Bytes; +use gst::glib; use gst::gst_debug; use gst::subclass::prelude::*; use gst::SECOND_VAL; diff --git a/video/cdg/src/cdgparse/mod.rs b/video/cdg/src/cdgparse/mod.rs index e1cf77f9..605f90f2 100644 --- a/video/cdg/src/cdgparse/mod.rs +++ b/video/cdg/src/cdgparse/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/video/cdg/src/lib.rs b/video/cdg/src/lib.rs index e6a4ffb2..5e5e1e14 100644 --- a/video/cdg/src/lib.rs +++ b/video/cdg/src/lib.rs @@ -6,6 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. +use gst::glib; + mod cdgdec; mod cdgparse; mod constants; diff --git a/video/cdg/src/typefind.rs b/video/cdg/src/typefind.rs index 4b907777..9add2469 100644 --- a/video/cdg/src/typefind.rs +++ b/video/cdg/src/typefind.rs @@ -6,6 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. +use gst::glib; + use crate::constants::{CDG_COMMAND, CDG_MASK, CDG_PACKET_PERIOD, CDG_PACKET_SIZE}; use gst::{Caps, TypeFind, TypeFindProbability}; use std::cmp; diff --git a/video/closedcaption/Cargo.toml b/video/closedcaption/Cargo.toml index 2056e397..b8d4a09b 100644 --- a/video/closedcaption/Cargo.toml +++ b/video/closedcaption/Cargo.toml @@ -8,7 +8,6 @@ description = "Rust Closed Caption Plugin" repository = "https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs" [dependencies] -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } nom = "6.0" either = "1" uuid = { version = "0.8", features = ["v4"] } diff --git a/video/closedcaption/src/ccdetect/imp.rs b/video/closedcaption/src/ccdetect/imp.rs index 488039df..2af76e96 100644 --- a/video/closedcaption/src/ccdetect/imp.rs +++ b/video/closedcaption/src/ccdetect/imp.rs @@ -15,7 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_trace, gst_warning}; diff --git a/video/closedcaption/src/ccdetect/mod.rs b/video/closedcaption/src/ccdetect/mod.rs index 609609c0..4f1a8311 100644 --- a/video/closedcaption/src/ccdetect/mod.rs +++ b/video/closedcaption/src/ccdetect/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/video/closedcaption/src/cea608overlay/imp.rs b/video/closedcaption/src/cea608overlay/imp.rs index 7fad6860..612d6f3a 100644 --- a/video/closedcaption/src/cea608overlay/imp.rs +++ b/video/closedcaption/src/cea608overlay/imp.rs @@ -15,7 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_error, gst_info, gst_log, gst_trace, gst_warning}; diff --git a/video/closedcaption/src/cea608overlay/mod.rs b/video/closedcaption/src/cea608overlay/mod.rs index 21605866..61c4ee23 100644 --- a/video/closedcaption/src/cea608overlay/mod.rs +++ b/video/closedcaption/src/cea608overlay/mod.rs @@ -21,7 +21,8 @@ // videotestsrc ! video/x-raw, width=1280, height=720 ! queue ! ccc.sink \ // filesrc location=input.srt ! subparse ! tttocea608 ! queue ! ccc.caption -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/video/closedcaption/src/cea608tojson/imp.rs b/video/closedcaption/src/cea608tojson/imp.rs index c245b51a..9544d898 100644 --- a/video/closedcaption/src/cea608tojson/imp.rs +++ b/video/closedcaption/src/cea608tojson/imp.rs @@ -25,7 +25,7 @@ // * The Chunk object could have an "indent" field, that would get translated // to tab offsets for small bandwidth savings -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_log, gst_trace, gst_warning}; diff --git a/video/closedcaption/src/cea608tojson/mod.rs b/video/closedcaption/src/cea608tojson/mod.rs index 88a1e2a5..42bbef79 100644 --- a/video/closedcaption/src/cea608tojson/mod.rs +++ b/video/closedcaption/src/cea608tojson/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/video/closedcaption/src/cea608tott/imp.rs b/video/closedcaption/src/cea608tott/imp.rs index da27a013..0b718e73 100644 --- a/video/closedcaption/src/cea608tott/imp.rs +++ b/video/closedcaption/src/cea608tott/imp.rs @@ -6,7 +6,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_log, gst_trace}; diff --git a/video/closedcaption/src/cea608tott/mod.rs b/video/closedcaption/src/cea608tott/mod.rs index f825453b..dadcf01a 100644 --- a/video/closedcaption/src/cea608tott/mod.rs +++ b/video/closedcaption/src/cea608tott/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/video/closedcaption/src/lib.rs b/video/closedcaption/src/lib.rs index 8c948e3f..45ed1f42 100644 --- a/video/closedcaption/src/lib.rs +++ b/video/closedcaption/src/lib.rs @@ -17,6 +17,8 @@ #![recursion_limit = "128"] +use gst::glib; + #[allow(non_camel_case_types, non_upper_case_globals, unused)] #[allow(clippy::redundant_static_lifetimes, clippy::unreadable_literal)] #[allow(clippy::useless_transmute, clippy::trivially_copy_pass_by_ref)] diff --git a/video/closedcaption/src/mcc_enc/imp.rs b/video/closedcaption/src/mcc_enc/imp.rs index 8fcd1c79..dcadcf9e 100644 --- a/video/closedcaption/src/mcc_enc/imp.rs +++ b/video/closedcaption/src/mcc_enc/imp.rs @@ -15,8 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::structure; use gst::subclass::prelude::*; diff --git a/video/closedcaption/src/mcc_enc/mod.rs b/video/closedcaption/src/mcc_enc/mod.rs index 8689e0ed..2d9a9ac4 100644 --- a/video/closedcaption/src/mcc_enc/mod.rs +++ b/video/closedcaption/src/mcc_enc/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod headers; mod imp; diff --git a/video/closedcaption/src/mcc_parse/imp.rs b/video/closedcaption/src/mcc_parse/imp.rs index 861bf30a..5d499689 100644 --- a/video/closedcaption/src/mcc_parse/imp.rs +++ b/video/closedcaption/src/mcc_parse/imp.rs @@ -15,8 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{ diff --git a/video/closedcaption/src/mcc_parse/mod.rs b/video/closedcaption/src/mcc_parse/mod.rs index 1f5a6ed0..b4ef031d 100644 --- a/video/closedcaption/src/mcc_parse/mod.rs +++ b/video/closedcaption/src/mcc_parse/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; mod parser; diff --git a/video/closedcaption/src/scc_enc/imp.rs b/video/closedcaption/src/scc_enc/imp.rs index 07275500..20ec459d 100644 --- a/video/closedcaption/src/scc_enc/imp.rs +++ b/video/closedcaption/src/scc_enc/imp.rs @@ -16,7 +16,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::structure; use gst::subclass::prelude::*; diff --git a/video/closedcaption/src/scc_enc/mod.rs b/video/closedcaption/src/scc_enc/mod.rs index 9eb34044..e157456b 100644 --- a/video/closedcaption/src/scc_enc/mod.rs +++ b/video/closedcaption/src/scc_enc/mod.rs @@ -16,7 +16,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/video/closedcaption/src/scc_parse/imp.rs b/video/closedcaption/src/scc_parse/imp.rs index dccbabba..47d5f6fb 100644 --- a/video/closedcaption/src/scc_parse/imp.rs +++ b/video/closedcaption/src/scc_parse/imp.rs @@ -16,7 +16,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{ diff --git a/video/closedcaption/src/scc_parse/mod.rs b/video/closedcaption/src/scc_parse/mod.rs index 362a93e9..2a74e294 100644 --- a/video/closedcaption/src/scc_parse/mod.rs +++ b/video/closedcaption/src/scc_parse/mod.rs @@ -16,7 +16,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; mod parser; diff --git a/video/closedcaption/src/tttocea608/imp.rs b/video/closedcaption/src/tttocea608/imp.rs index 6534d2b9..a880f3eb 100644 --- a/video/closedcaption/src/tttocea608/imp.rs +++ b/video/closedcaption/src/tttocea608/imp.rs @@ -15,8 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_log, gst_trace, gst_warning}; diff --git a/video/closedcaption/src/tttocea608/mod.rs b/video/closedcaption/src/tttocea608/mod.rs index 3e240132..16549058 100644 --- a/video/closedcaption/src/tttocea608/mod.rs +++ b/video/closedcaption/src/tttocea608/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/video/closedcaption/src/tttojson/imp.rs b/video/closedcaption/src/tttojson/imp.rs index c3c9799a..8b79617a 100644 --- a/video/closedcaption/src/tttojson/imp.rs +++ b/video/closedcaption/src/tttojson/imp.rs @@ -15,7 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::subclass::prelude::*; +use gst::glib; use gst::gst_log; use gst::prelude::*; use gst::subclass::prelude::*; diff --git a/video/closedcaption/src/tttojson/mod.rs b/video/closedcaption/src/tttojson/mod.rs index 6c1c3b41..b79be3c8 100644 --- a/video/closedcaption/src/tttojson/mod.rs +++ b/video/closedcaption/src/tttojson/mod.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/video/closedcaption/src/ttutils.rs b/video/closedcaption/src/ttutils.rs index 2c3be539..aa1c81ca 100644 --- a/video/closedcaption/src/ttutils.rs +++ b/video/closedcaption/src/ttutils.rs @@ -15,6 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. +use gst::glib; use serde::{Deserialize, Serialize}; #[derive( diff --git a/video/closedcaption/tests/mcc_enc.rs b/video/closedcaption/tests/mcc_enc.rs index f8fe6016..e438416f 100644 --- a/video/closedcaption/tests/mcc_enc.rs +++ b/video/closedcaption/tests/mcc_enc.rs @@ -15,7 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; use pretty_assertions::assert_eq; diff --git a/video/dav1d/Cargo.toml b/video/dav1d/Cargo.toml index 87ca7b3d..d0f37e63 100644 --- a/video/dav1d/Cargo.toml +++ b/video/dav1d/Cargo.toml @@ -9,7 +9,6 @@ description = "Dav1d Plugin" [dependencies] dav1d = "0.6" -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } gst = { package = "gstreamer", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gst-base = { package = "gstreamer-base", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gst-video = { package = "gstreamer-video", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs", features = ["v1_12"] } diff --git a/video/dav1d/src/dav1ddec/imp.rs b/video/dav1d/src/dav1ddec/imp.rs index f94317fd..fb179bb0 100644 --- a/video/dav1d/src/dav1ddec/imp.rs +++ b/video/dav1d/src/dav1ddec/imp.rs @@ -6,7 +6,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_info, gst_trace, gst_warning}; diff --git a/video/dav1d/src/dav1ddec/mod.rs b/video/dav1d/src/dav1ddec/mod.rs index efe7c32a..dc13b249 100644 --- a/video/dav1d/src/dav1ddec/mod.rs +++ b/video/dav1d/src/dav1ddec/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/video/dav1d/src/lib.rs b/video/dav1d/src/lib.rs index 6ad39629..53311608 100644 --- a/video/dav1d/src/lib.rs +++ b/video/dav1d/src/lib.rs @@ -6,6 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. +use gst::glib; + mod dav1ddec; fn plugin_init(plugin: &gst::Plugin) -> Result<(), glib::BoolError> { diff --git a/video/flavors/Cargo.toml b/video/flavors/Cargo.toml index edf05bcd..ad916afc 100644 --- a/video/flavors/Cargo.toml +++ b/video/flavors/Cargo.toml @@ -8,7 +8,6 @@ edition = "2018" description = "Rust FLV Plugin" [dependencies] -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } gst = { package = "gstreamer", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gst-base = { package = "gstreamer-base", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } num-rational = { version = "0.4", default-features = false, features = [] } diff --git a/video/flavors/src/flvdemux/imp.rs b/video/flavors/src/flvdemux/imp.rs index 89bcdbf7..ee7e0b7b 100644 --- a/video/flavors/src/flvdemux/imp.rs +++ b/video/flavors/src/flvdemux/imp.rs @@ -13,6 +13,7 @@ use std::sync::Mutex; #[rustfmt::skip] use ::flavors::parser as flavors; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error, gst_log, gst_trace, gst_warning}; diff --git a/video/flavors/src/flvdemux/mod.rs b/video/flavors/src/flvdemux/mod.rs index b27abffa..86f9cc4c 100644 --- a/video/flavors/src/flvdemux/mod.rs +++ b/video/flavors/src/flvdemux/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/video/flavors/src/lib.rs b/video/flavors/src/lib.rs index e7aa0266..15459777 100644 --- a/video/flavors/src/lib.rs +++ b/video/flavors/src/lib.rs @@ -6,6 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. +use gst::glib; + mod bytes; mod flvdemux; diff --git a/video/gif/Cargo.toml b/video/gif/Cargo.toml index c0834168..2f3d8b56 100644 --- a/video/gif/Cargo.toml +++ b/video/gif/Cargo.toml @@ -8,7 +8,6 @@ edition = "2018" description = "GStreamer GIF plugin" [dependencies] -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } gst = { package = "gstreamer", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gst-video = { package = "gstreamer-video", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gif = "0.11" diff --git a/video/gif/src/gifenc/imp.rs b/video/gif/src/gifenc/imp.rs index 0fbc04d9..873e2271 100644 --- a/video/gif/src/gifenc/imp.rs +++ b/video/gif/src/gifenc/imp.rs @@ -7,7 +7,7 @@ // except according to those terms. use atomic_refcell::AtomicRefCell; -use glib::subclass::prelude::*; +use gst::glib; use gst::gst_debug; use gst::subclass::prelude::*; use gst_video::prelude::*; diff --git a/video/gif/src/gifenc/mod.rs b/video/gif/src/gifenc/mod.rs index 8fc9da5b..6ebf0c2c 100644 --- a/video/gif/src/gifenc/mod.rs +++ b/video/gif/src/gifenc/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/video/gif/src/lib.rs b/video/gif/src/lib.rs index b1e637ce..2c8e7f4a 100644 --- a/video/gif/src/lib.rs +++ b/video/gif/src/lib.rs @@ -6,6 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. +use gst::glib; + mod gifenc; fn plugin_init(plugin: &gst::Plugin) -> Result<(), glib::BoolError> { diff --git a/video/hsv/Cargo.toml b/video/hsv/Cargo.toml index 80e8610f..60cb476c 100644 --- a/video/hsv/Cargo.toml +++ b/video/hsv/Cargo.toml @@ -8,7 +8,6 @@ edition = "2018" description = "HSV manipulation elements, written in Rust" [dependencies] -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } gst = { package = "gstreamer", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gst-base = { package = "gstreamer-base", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gst-video = { package = "gstreamer-video", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } diff --git a/video/hsv/src/hsvdetector/imp.rs b/video/hsv/src/hsvdetector/imp.rs index 896e8c73..48749205 100644 --- a/video/hsv/src/hsvdetector/imp.rs +++ b/video/hsv/src/hsvdetector/imp.rs @@ -6,7 +6,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; diff --git a/video/hsv/src/hsvdetector/mod.rs b/video/hsv/src/hsvdetector/mod.rs index 65c4ddfa..c4c7b97b 100644 --- a/video/hsv/src/hsvdetector/mod.rs +++ b/video/hsv/src/hsvdetector/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/video/hsv/src/hsvfilter/imp.rs b/video/hsv/src/hsvfilter/imp.rs index a527c13f..1f124b1a 100644 --- a/video/hsv/src/hsvfilter/imp.rs +++ b/video/hsv/src/hsvfilter/imp.rs @@ -6,7 +6,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_info}; diff --git a/video/hsv/src/hsvfilter/mod.rs b/video/hsv/src/hsvfilter/mod.rs index 720ed86c..37cd6b63 100644 --- a/video/hsv/src/hsvfilter/mod.rs +++ b/video/hsv/src/hsvfilter/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/video/hsv/src/lib.rs b/video/hsv/src/lib.rs index d78efdb3..fd3f63b9 100644 --- a/video/hsv/src/lib.rs +++ b/video/hsv/src/lib.rs @@ -6,6 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. +use gst::glib; + mod hsvdetector; mod hsvfilter; mod hsvutils; diff --git a/video/rav1e/Cargo.toml b/video/rav1e/Cargo.toml index eca2800f..eb885835 100644 --- a/video/rav1e/Cargo.toml +++ b/video/rav1e/Cargo.toml @@ -8,7 +8,6 @@ description = "rav1e AV1 Encoder Plugin" edition = "2018" [dependencies] -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } gst = { package = "gstreamer", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gst-video = { package = "gstreamer-video", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs", features = ["v1_12"] } rav1e = { version = "0.4", default-features = false } diff --git a/video/rav1e/src/lib.rs b/video/rav1e/src/lib.rs index 1e0e307d..9a0db00c 100644 --- a/video/rav1e/src/lib.rs +++ b/video/rav1e/src/lib.rs @@ -6,6 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. +use gst::glib; + mod rav1enc; fn plugin_init(plugin: &gst::Plugin) -> Result<(), glib::BoolError> { diff --git a/video/rav1e/src/rav1enc/imp.rs b/video/rav1e/src/rav1enc/imp.rs index 04a70ec2..9a313340 100644 --- a/video/rav1e/src/rav1enc/imp.rs +++ b/video/rav1e/src/rav1enc/imp.rs @@ -6,7 +6,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::subclass::prelude::*; +use gst::glib; use gst::gst_debug; use gst::subclass::prelude::*; use gst_video::prelude::*; diff --git a/video/rav1e/src/rav1enc/mod.rs b/video/rav1e/src/rav1enc/mod.rs index 409c59d0..7020ff6d 100644 --- a/video/rav1e/src/rav1enc/mod.rs +++ b/video/rav1e/src/rav1enc/mod.rs @@ -6,7 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/video/rav1e/tests/rav1enc.rs b/video/rav1e/tests/rav1enc.rs index 4e65e59c..bae68a1e 100644 --- a/video/rav1e/tests/rav1enc.rs +++ b/video/rav1e/tests/rav1enc.rs @@ -6,7 +6,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; +use gst::prelude::*; fn init() { use std::sync::Once; diff --git a/video/rspng/Cargo.toml b/video/rspng/Cargo.toml index ab1e79ea..8649b170 100644 --- a/video/rspng/Cargo.toml +++ b/video/rspng/Cargo.toml @@ -8,7 +8,6 @@ edition = "2018" description = "An PNG encoder/decoder written in pure Rust" [dependencies] -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } gst = { package = "gstreamer", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } gst_video = { package = "gstreamer-video", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" } png = "0.16.3" diff --git a/video/rspng/src/lib.rs b/video/rspng/src/lib.rs index 46ea9712..37ab4edc 100644 --- a/video/rspng/src/lib.rs +++ b/video/rspng/src/lib.rs @@ -6,6 +6,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. +use gst::glib; + mod pngenc; fn plugin_init(plugin: &gst::Plugin) -> Result<(), glib::BoolError> { diff --git a/video/rspng/src/pngenc/imp.rs b/video/rspng/src/pngenc/imp.rs index 6836d78c..bc0b01c0 100644 --- a/video/rspng/src/pngenc/imp.rs +++ b/video/rspng/src/pngenc/imp.rs @@ -8,8 +8,7 @@ use std::{io, io::Write, sync::Arc}; -use glib::subclass::prelude::*; - +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_debug, gst_error}; diff --git a/video/rspng/src/pngenc/mod.rs b/video/rspng/src/pngenc/mod.rs index c5a1d878..9abe76ba 100644 --- a/video/rspng/src/pngenc/mod.rs +++ b/video/rspng/src/pngenc/mod.rs @@ -6,8 +6,9 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use glib::prelude::*; use glib::GEnum; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/video/webp/Cargo.toml b/video/webp/Cargo.toml index f103b982..8a98ed7d 100644 --- a/video/webp/Cargo.toml +++ b/video/webp/Cargo.toml @@ -8,7 +8,6 @@ description = "WebP Plugin" repository = "https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs" [dependencies] -glib = { git = "https://github.com/gtk-rs/gtk-rs-core" } once_cell = "1.0" libwebp-sys2 = { version = "0.1.2", features = ["demux", "0_5"] } diff --git a/video/webp/src/dec/imp.rs b/video/webp/src/dec/imp.rs index 0060284a..88729e4b 100644 --- a/video/webp/src/dec/imp.rs +++ b/video/webp/src/dec/imp.rs @@ -15,7 +15,7 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. -use glib::subclass::prelude::*; +use gst::glib; use gst::prelude::*; use gst::subclass::prelude::*; use gst::{gst_log, gst_trace}; diff --git a/video/webp/src/dec/mod.rs b/video/webp/src/dec/mod.rs index f8dff358..b670a190 100644 --- a/video/webp/src/dec/mod.rs +++ b/video/webp/src/dec/mod.rs @@ -19,7 +19,8 @@ // // gst-launch-1.0 filesrc location=animated.webp ! webpdec-rs ! videoconvert ! autovideosink -use glib::prelude::*; +use gst::glib; +use gst::prelude::*; mod imp; diff --git a/video/webp/src/lib.rs b/video/webp/src/lib.rs index 64891231..139974f0 100644 --- a/video/webp/src/lib.rs +++ b/video/webp/src/lib.rs @@ -15,6 +15,8 @@ // Free Software Foundation, Inc., 51 Franklin Street, Suite 500, // Boston, MA 02110-1335, USA. +use gst::glib; + mod dec; fn plugin_init(plugin: &gst::Plugin) -> Result<(), glib::BoolError> {