slint/examples/gstreamer-player
2024-09-25 11:49:15 +00:00
..
build.rs Rename gstreamer_player to streamer-player 2024-02-07 11:22:48 +01:00
Cargo.toml Bump version number to 1.9.0 2024-09-25 11:49:15 +00:00
main.rs Rename gstreamer_player to streamer-player 2024-02-07 11:22:48 +01:00
pause.svg Rename gstreamer_player to streamer-player 2024-02-07 11:22:48 +01:00
play.svg Rename gstreamer_player to streamer-player 2024-02-07 11:22:48 +01:00
README.md Add info about gstreamer package necessary for building example 2024-02-19 17:50:22 +01:00
scene.slint Remove stray imports of StyleMetrics 2024-07-12 09:13:35 +02:00

GStreamer Example

This example application demonstrates a way to use gstreamer (with Rust bindings) to display a video stream in Slint.

Current Status: This started as a fork of the ffmpeg example, but doesn't implement everything in the ffmpeg example yet:

  • Play/Pause functionaly has not been implemented.
  • The code has so far only been tested on Ubuntu.
  • We use gstreamer's test source instead of streaming a video off the internet to save bandwidth and make the example more self contained.

Building and Running

You will need to have the gstreamer libraries used by gstreamer-rs installed.

https://gstreamer.pages.freedesktop.org/gstreamer-rs/stable/latest/docs/gstreamer/

On Debian/Ubuntu you can use:

$ apt-get install libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev \
      gstreamer1.0-plugins-base gstreamer1.0-plugins-good \
      gstreamer1.0-plugins-bad gstreamer1.0-plugins-ugly \
      gstreamer1.0-libav libgstrtspserver-1.0-dev libges-1.0-dev

On Opensuse you can use:

$ zypper in zypper in gstreamer-plugins-bad-devel gstreamer-devel gstreamer-plugins-base-devel \
      gstreamer-plugins-good

Once you have a working gstreamer-rs and slint install, cargo run should work.