forked from mirrors/gstreamer-rs
tutorials: update old gstreamer-sdk media links
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1304>
This commit is contained in:
parent
277cb517cd
commit
db16dca822
10 changed files with 13 additions and 19 deletions
|
@ -8,8 +8,7 @@ fn tutorial_main() {
|
||||||
gst::init().unwrap();
|
gst::init().unwrap();
|
||||||
|
|
||||||
// Build the pipeline
|
// Build the pipeline
|
||||||
let uri =
|
let uri = "https://gstreamer.freedesktop.org/data/media/sintel_trailer-480p.webm";
|
||||||
"https://www.freedesktop.org/software/gstreamer-sdk/data/media/sintel_trailer-480p.webm";
|
|
||||||
let pipeline = gst::parse_launch(&format!("playbin uri={uri}")).unwrap();
|
let pipeline = gst::parse_launch(&format!("playbin uri={uri}")).unwrap();
|
||||||
|
|
||||||
// Start playing
|
// Start playing
|
||||||
|
|
|
@ -11,8 +11,7 @@ fn tutorial_main() -> Result<(), Error> {
|
||||||
gst::init()?;
|
gst::init()?;
|
||||||
|
|
||||||
// Build the pipeline
|
// Build the pipeline
|
||||||
let uri =
|
let uri = "https://gstreamer.freedesktop.org/data/media/sintel_trailer-480p.webm";
|
||||||
"https://www.freedesktop.org/software/gstreamer-sdk/data/media/sintel_trailer-480p.webm";
|
|
||||||
let pipeline = gst::parse_launch(&format!("playbin uri={uri}"))?;
|
let pipeline = gst::parse_launch(&format!("playbin uri={uri}"))?;
|
||||||
|
|
||||||
// Start playing
|
// Start playing
|
||||||
|
|
|
@ -121,8 +121,7 @@ USAGE: Choose one of the following options, then press enter:
|
||||||
thread::spawn(move || handle_keyboard(ready_tx));
|
thread::spawn(move || handle_keyboard(ready_tx));
|
||||||
|
|
||||||
// Build the pipeline.
|
// Build the pipeline.
|
||||||
let uri =
|
let uri = "https://gstreamer.freedesktop.org/data/media/sintel_trailer-480p.webm";
|
||||||
"https://www.freedesktop.org/software/gstreamer-sdk/data/media/sintel_trailer-480p.webm";
|
|
||||||
let pipeline = gst::parse_launch(&format!("playbin uri={uri}"))?;
|
let pipeline = gst::parse_launch(&format!("playbin uri={uri}"))?;
|
||||||
|
|
||||||
// Start playing.
|
// Start playing.
|
||||||
|
|
|
@ -24,8 +24,7 @@ fn tutorial_main() {
|
||||||
// Initialize GStreamer
|
// Initialize GStreamer
|
||||||
gst::init().unwrap();
|
gst::init().unwrap();
|
||||||
|
|
||||||
let uri =
|
let uri = "https://gstreamer.freedesktop.org/data/media/sintel_trailer-480p.webm";
|
||||||
"https://www.freedesktop.org/software/gstreamer-sdk/data/media/sintel_trailer-480p.webm";
|
|
||||||
|
|
||||||
// Creat the playbin element
|
// Creat the playbin element
|
||||||
let playbin = gst::ElementFactory::make("playbin")
|
let playbin = gst::ElementFactory::make("playbin")
|
||||||
|
|
|
@ -142,7 +142,7 @@ fn run_discoverer() -> Result<(), Error> {
|
||||||
let uri: &str = if args.len() == 2 {
|
let uri: &str = if args.len() == 2 {
|
||||||
args[1].as_ref()
|
args[1].as_ref()
|
||||||
} else {
|
} else {
|
||||||
"https://www.freedesktop.org/software/gstreamer-sdk/data/media/sintel_trailer-480p.webm"
|
"https://gstreamer.freedesktop.org/data/media/sintel_trailer-480p.webm"
|
||||||
};
|
};
|
||||||
|
|
||||||
println!("Discovering {uri}");
|
println!("Discovering {uri}");
|
||||||
|
|
|
@ -100,8 +100,7 @@ fn tutorial_main() -> Result<(), Error> {
|
||||||
// Initialize GStreamer
|
// Initialize GStreamer
|
||||||
gst::init()?;
|
gst::init()?;
|
||||||
|
|
||||||
let uri =
|
let uri = "https://gstreamer.freedesktop.org/data/media/sintel_cropped_multilingual.webm";
|
||||||
"https://www.freedesktop.org/software/gstreamer-sdk/data/media/sintel_cropped_multilingual.webm";
|
|
||||||
|
|
||||||
// Create PlayBin element
|
// Create PlayBin element
|
||||||
let playbin = gst::ElementFactory::make("playbin")
|
let playbin = gst::ElementFactory::make("playbin")
|
||||||
|
|
|
@ -102,10 +102,8 @@ fn tutorial_main() -> Result<(), Error> {
|
||||||
// Initialize GStreamer
|
// Initialize GStreamer
|
||||||
gst::init()?;
|
gst::init()?;
|
||||||
|
|
||||||
let uri =
|
let uri = "https://gstreamer.freedesktop.org/data/media/sintel_trailer-480p.ogv";
|
||||||
"https://www.freedesktop.org/software/gstreamer-sdk/data/media/sintel_trailer-480p.ogv";
|
let subtitle_uri = "https://gstreamer.freedesktop.org/data/media/sintel_trailer_gr.srt";
|
||||||
let subtitle_uri =
|
|
||||||
"https://www.freedesktop.org/software/gstreamer-sdk/data/media/sintel_trailer_gr.srt";
|
|
||||||
|
|
||||||
// Create PlayBin element
|
// Create PlayBin element
|
||||||
let playbin = gst::ElementFactory::make("playbin")
|
let playbin = gst::ElementFactory::make("playbin")
|
||||||
|
|
|
@ -17,8 +17,7 @@ fn tutorial_main() -> Result<(), Error> {
|
||||||
gst::init()?;
|
gst::init()?;
|
||||||
|
|
||||||
// Build the pipeline
|
// Build the pipeline
|
||||||
let uri =
|
let uri = "https://gstreamer.freedesktop.org/data/media/sintel_trailer-480p.webm";
|
||||||
"https://www.freedesktop.org/software/gstreamer-sdk/data/media/sintel_trailer-480p.webm";
|
|
||||||
let pipeline = gst::ElementFactory::make("playbin")
|
let pipeline = gst::ElementFactory::make("playbin")
|
||||||
.name("playbin")
|
.name("playbin")
|
||||||
.property("uri", uri)
|
.property("uri", uri)
|
||||||
|
|
|
@ -111,7 +111,8 @@ fn tutorial_main() -> Result<(), Error> {
|
||||||
|
|
||||||
// Build the pipeline
|
// Build the pipeline
|
||||||
let pipeline = gst::parse_launch(
|
let pipeline = gst::parse_launch(
|
||||||
"playbin uri=https://www.freedesktop.org/software/gstreamer-sdk/data/media/sintel_trailer-480p.webm")?;
|
"playbin uri=https://gstreamer.freedesktop.org/data/media/sintel_trailer-480p.webm",
|
||||||
|
)?;
|
||||||
|
|
||||||
let main_loop = glib::MainLoop::new(None, false);
|
let main_loop = glib::MainLoop::new(None, false);
|
||||||
let main_loop_clone = main_loop.clone();
|
let main_loop_clone = main_loop.clone();
|
||||||
|
|
|
@ -10,7 +10,8 @@ fn tutorial_main() -> Result<(), Error> {
|
||||||
|
|
||||||
// Build the pipeline
|
// Build the pipeline
|
||||||
let pipeline = gst::parse_launch(
|
let pipeline = gst::parse_launch(
|
||||||
"playbin uri=https://www.freedesktop.org/software/gstreamer-sdk/data/media/sintel_trailer-480p.webm")?;
|
"playbin uri=https://gstreamer.freedesktop.org/data/media/sintel_trailer-480p.webm",
|
||||||
|
)?;
|
||||||
|
|
||||||
// Create elements that go inside the sink bin
|
// Create elements that go inside the sink bin
|
||||||
let equalizer = gst::ElementFactory::make("equalizer-3bands")
|
let equalizer = gst::ElementFactory::make("equalizer-3bands")
|
||||||
|
|
Loading…
Reference in a new issue