From 81174152aaf37594acbc7cd7e96a242374cef6ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tim-Philipp=20M=C3=BCller?= Date: Tue, 23 May 2023 17:48:00 +0100 Subject: [PATCH] gst-python: add proper README and delete useless placeholder files Fixes https://gitlab.freedesktop.org/gstreamer/gst-python/-/issues/54 Part-of: --- subprojects/gst-python/AUTHORS | 1 - subprojects/gst-python/README | 1 - subprojects/gst-python/README.md | 50 ++++++++++++++++++++++++++++++++ subprojects/gst-python/TODO | 1 - 4 files changed, 50 insertions(+), 3 deletions(-) delete mode 100644 subprojects/gst-python/AUTHORS delete mode 100644 subprojects/gst-python/README create mode 100644 subprojects/gst-python/README.md delete mode 100644 subprojects/gst-python/TODO diff --git a/subprojects/gst-python/AUTHORS b/subprojects/gst-python/AUTHORS deleted file mode 100644 index 92ffc66cfb..0000000000 --- a/subprojects/gst-python/AUTHORS +++ /dev/null @@ -1 +0,0 @@ -This file will be autogenerated. Please read README-docs. diff --git a/subprojects/gst-python/README b/subprojects/gst-python/README deleted file mode 100644 index 92ffc66cfb..0000000000 --- a/subprojects/gst-python/README +++ /dev/null @@ -1 +0,0 @@ -This file will be autogenerated. Please read README-docs. diff --git a/subprojects/gst-python/README.md b/subprojects/gst-python/README.md new file mode 100644 index 0000000000..4ee2e7ff83 --- /dev/null +++ b/subprojects/gst-python/README.md @@ -0,0 +1,50 @@ +# gst-python + +gst-python is an extension of the regular GStreamer Python bindings +based on gobject-introspection information and PyGObject. + +It provides two things: + +1. "syntactic sugar" in form of overrides for various GStreamer APIs + that makes them easier to use in Python and more pythonic; and + +2. support for APIs that aren't available through the regular + gobject-introspection based bindings, such as e.g. GStreamer's + fundamental GLib types such as `Gst.Fraction`, `Gst.IntRange` etc. + +## Prerequisites + +These libraries are needed to build gst-python: + - gstreamer core + - gst-plugins-base + - pygobject + +You will also need pygobject and glib installed. On debian-based distros +you can install these with: + + sudo apt build-dep python3-gst-1.0 + +Only Python 3 is supported. + +## Building + + meson setup builddir && ninja -C builddir + meson install -C builddir + +## Using + +Once installed in the right place, you don't need to do anything in order +to use the overrides. They will be loaded automatically on + +```python +import gi +gi.require_version('Gst', '1.0') +gi.repository import GObject, Gst +``` + +Note that additional imports will be required for other GStreamer libraries to +make use of their respective APIs, e.g. `GstApp` or `GstVideo`. + +## License + +gst-python is licensed under the [LGPL 2.1](https://www.gnu.org/licenses/lgpl-2.1.html) diff --git a/subprojects/gst-python/TODO b/subprojects/gst-python/TODO deleted file mode 100644 index e2fafcedaf..0000000000 --- a/subprojects/gst-python/TODO +++ /dev/null @@ -1 +0,0 @@ -Port old examples to GStreamer 1.0