Sebastian Dröge
3fd3a32b6f
video/gtk4: Clean up GStreamer GL context initialization
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1708 >
2024-08-23 08:11:15 +00:00
Jordan Petridis
4f01421cc4
video/gtk4: Make feature "v4_6" the default assumption
...
It's our minimum gtk4 version we target anyway so we
can remove some of the extra features in the toml and require
it by default.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1708 >
2024-08-23 08:11:15 +00:00
Jordan Petridis
ff5032934d
video/gtk4: Remove some indentation in frame.rs
...
We have less cfg features now and don't need the extra
brackets to guard the codepaths.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1708 >
2024-08-23 08:11:15 +00:00
Jordan Petridis
602760d0d8
video/gtk4: Remove cfg flag for gst-gl
...
GTK 4 hard depends on GL on all platforms, and now both
windows and macos have codepaths for the paintable sink to
produce GLTextures.
This we can now drop the cfg build flag we have making it optional.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1708 >
2024-08-23 08:11:15 +00:00
Guillaume Desmottes
72e53b9f16
videofx: update image and image_hasher deps
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1707 >
2024-08-13 07:21:59 +00:00
Guillaume Desmottes
ea29052c39
cdg: update to image 0.25
...
I just published a new cdg_renderer release depending of image 0.25.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1707 >
2024-08-13 07:21:59 +00:00
Guillaume Desmottes
cfe9968a77
gtk4: add custom widget automatically updating the window size
...
Use it in the example and debug window but let's not make it public yet.
Plan is to have a proper bin on top of gtk4paintablesink at some point.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1680 >
2024-08-06 10:29:41 +00:00
Guillaume Desmottes
17910dd532
gtk4: add window-{width,height} property
...
Allow the application to pass the actual rendering size so overlays can
be rendered accordingly.
Fix #562
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1680 >
2024-08-06 10:29:41 +00:00
Guillaume Desmottes
2333b241f0
gtk4: log paintable size in snapshot
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1689 >
2024-08-05 15:53:19 +02:00
Jordan Petridis
1316b821c4
video/gtk4: Move the dmabuf cfg to the correct bracket level
...
This was defined one bracket above, which was causing the
gst-gl codepath below to also be disabled when there was
no dmabuf feature enabled.
This was also resulting in the following warning as
we were never creating the MappedFrame::GL vartiant due to this
```
warning: unused variable: `wrapped_context`
--> video/gtk4/src/sink/frame.rs:541:85
|
541 | ...", feature = "gst-gl"))] wrapped_context: Option<
| ^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_wrapped_context`
|
= note: `#[warn(unused_variables)]` on by default
warning: variant `GL` is never constructed
--> video/gtk4/src/sink/frame.rs:80:5
|
74 | enum MappedFrame {
| ----------- variant in this enum
...
```
Move the cfg to the appropriate place where it encaplsulates only
the dmabuf related code.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1682 >
2024-08-01 15:44:58 +03:00
Mathieu Duponchelle
79657e5671
transcriberbin: fix inspect with missing elements
...
Relax the dependency on `awstranscriber` by still building the initial
state when it is absent, this also means an alternative transcriber can
be linked even when `awstranscriber` was not available during
construction.
Also fix property getter / setters to avoid unwrapping the pad state,
and bubble up channel bin construction errors instead of unwrapping (eg
when textwrap was not available).
Fixes: https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/584
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1679 >
2024-07-29 08:38:36 +00:00
Sebastian Dröge
380448587b
gtk4: Enable GtkGraphicsOffload::black-background property when building with GTK 4.16
...
This allows offloading in more situations.
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/576
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1673 >
2024-07-18 12:28:20 +03:00
François Laignel
000c486568
rav1enc: document bitrate property unit
...
See:
e34e772e47/src/rate.rs (L365)
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1667 >
2024-07-12 18:59:17 +02:00
Robert Mader
c7ef8e8185
gtk4: Use scale instead of rotate where possible
...
In order to make it easier for GTK4 to figure out that the resulting
operation is 2D and - crucially - can get offloaded to Wayland.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1662 >
2024-07-10 10:58:20 +02:00
Robert Mader
2238db2005
gtk4: Support RGBx formats in SW paths
...
GTK4 has matching enums and thus should handle them fine. Further more
it should allow renderers to reduce memory bandwidth by applying
occlusion culling.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1660 >
2024-07-09 16:53:01 +02:00
Sebastian Dröge
3609411801
gtk4: Invalidate paintable size if changing because of orientation changes
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1659 >
2024-07-08 14:49:43 +03:00
Sebastian Dröge
98b28d69ce
Update for new debug log macro syntax
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1658 >
2024-07-08 11:25:23 +03:00
Sebastian Dröge
8522c8a445
gtk4: Add support for rotations / flipping
...
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/284
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1590 >
2024-07-07 07:43:49 +00:00
Sebastian Dröge
6e974cf4b9
gtk4: Document paintable properties correctly
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1655 >
2024-07-06 11:36:55 +00:00
Sebastian Dröge
195c089f18
gtk4: Declare correct default value for force-aspect-ratio
property
...
It's defaulting to false as generally keeping the aspect ratio is the
job of the widget layout and not the paintable.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1654 >
2024-07-06 13:41:44 +03:00
Mathieu Duponchelle
0ef886ea16
transcriberbin: fix internal ghost pad name regression
...
As part of https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1593
source pad names on inner transcription bins were appended a suffix, but
other pieces of the code were not updated to account for that.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1645 >
2024-07-01 11:47:39 +02:00
Jordan Petridіs
718e757669
video/gtk4: Dehardcode module name in the Flatpak example in the readme
2024-06-29 15:56:06 +00:00
Mathieu Duponchelle
f0df6874d8
transcriberbin: fix property proxying
...
As part of https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1546
the element started implementing the GstChildProxy interface in order to
expose properties on its sink pads, but the implementation was
incorrect and broke proxying to children elements.
In addition, an intermediary bin was introduced with no name, making it
hard to set the properties of the inner elements through the child
proxy interface, it is now named according to the name of the pad it
corresponds to.
Finally, the default transcriber is back to being named "transcriber".
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1642 >
2024-06-28 14:24:08 +00:00
Sebastian Dröge
9b323a6519
Use Option::is_some_and(...)
instead of Option::map_or(false, ...)
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1630 >
2024-06-19 13:03:37 +00:00
Sebastian Dröge
69c3c2ae46
Fix various new clippy 1.79 warnings
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1620 >
2024-06-14 08:33:49 +03:00
Jordan Petridis
f30cb2b56c
video/gtk4: Add --features to the flatpak example
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1608 >
2024-06-07 10:54:05 +00:00
Mathieu Duponchelle
7cec628c43
transcriberbin: make sure to always record pad property changes
...
When the pad isn't parented yet we should still record user choices,
either in our settings or in our state.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1593 >
2024-06-06 15:42:21 +00:00
Mathieu Duponchelle
0e85973e94
transcriberbin: fix regression with > 1 translation languages
...
By making sure to expose uniquely named pads on the inner transcription
bins.
Fixes: https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/552
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1593 >
2024-06-06 15:42:21 +00:00
Angelo Verlain
c9ac553cfe
gtk4: update flatpak integration code
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1600 >
2024-06-06 13:08:19 +00:00
Seungha Yang
ebdcc403cf
transcriberbin: Fix mux-method=cea708
...
* Update "translation-languages" property to include G_PARAM_CONSTRUCT
so that it can be applied to initial state.
* Change default "translation-languages" value to be None instead of
cea608 specific one. Transcriberbin will be able to configure initia
state depending on selected mux method if "translation-languages" is
unspecified.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1589 >
2024-05-30 04:40:09 +09:00
Matthew Waters
45800d7636
tttocea708: ensure periodic sync points in roll up mode
...
Otherwise, without the relevant DefineWindow, then a receiver cannot
begin to display the captions from the middle of a stream.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1591 >
2024-05-29 11:15:10 +00:00
Sebastian Dröge
b1ad123595
gtk4: Fix Python example in the non-GL code path
2024-05-23 16:15:52 +03:00
Sebastian Dröge
49d3dd17a2
gtk4: Clean up Python example
...
It's not more or less equivalent to the Rust example.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1573 >
2024-05-13 10:06:32 +03:00
Sebastian Dröge
b4576a0074
gtk4: Fix description of the plugin
...
A paintable is not a widget and that aspect does not belong in the short
description anyway.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1563 >
2024-05-07 20:21:03 +03:00
Sebastian Dröge
be3ae583bc
Fix new Rust 1.78 clippy warnings
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1559 >
2024-05-02 18:36:23 +03:00
Robert Mader
8e675de690
gtk4paintablesink: Add some documentation
...
And sync with `README.md` in order to make the environment variables
`GST_GTK4_WINDOW` and `GST_GTK4_WINDOW_FULLSCREEN` discoverable - and
because it's generally useful.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1555 >
2024-04-30 09:59:49 +03:00
Robert Mader
4326c3bfce
gtk4paintablesink: Also create window for gst-play
...
So it can be easily tested with
```
gst-play-1.0 --videosink=gtk4paintablesink ...
```
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1555 >
2024-04-29 22:44:56 +02:00
Robert Mader
47b788d44b
gtk4paintablesink: Add env var to fullscreen window
...
For testing purposes with e.g. gst-launch.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1555 >
2024-04-29 20:44:05 +00:00
Philippe Normand
88cbc93338
dav1ddec: Negotiate bt709 colorimetry when values from seq header are unspecified
...
With unknown range colorimetry validation would fail in video-info. As our
decoder outputs only YUV formats Bt709 should be a reasonable default.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1548 >
2024-04-26 19:35:41 +00:00
Sebastian Dröge
927c3fcdb6
gtk4paintablesink: Update README.md with all the new features
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1547 >
2024-04-26 12:29:10 +03:00
Sebastian Dröge
c95e07a897
gtk4paintablesink: Improve scaling logic
...
If force-aspect-ratio=false then make sure to fully fill the given
width/height with the video frame and avoid rounding errors. This makes
sure that the video is rendered in the exact position selected by the
caller and that graphics offloading is going to work more likely.
In other cases and for all overlays, make sure that the calculated
positions are staying inside (0, 0, width, height) as rendering outside
is not allowed by GTK.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1547 >
2024-04-26 12:29:10 +03:00
Sebastian Dröge
b42bd3d026
gtk4paintablesink: Add force-aspect-ratio property like in other video sinks
...
Unlike in other sinks this defaults to false as generally every user of
GDK paintables already ensures that the aspect ratio is kept and the
paintable is layed out in the most optimal way based on the context.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1547 >
2024-04-26 12:29:10 +03:00
Sebastian Dröge
3dd800ac77
gtk4paintablesink: Implement child proxy interface
...
This allows setting properties on the paintable from gst-launch-1.0.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1547 >
2024-04-26 12:29:10 +03:00
Sebastian Dröge
c92462b240
gtk4: Implement support for directly importing dmabufs
...
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/441
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1547 >
2024-04-26 12:29:10 +03:00
Mathieu Duponchelle
17d7997137
transcriberbin: add support for consuming secondary audio streams
...
In some situations, a translated alternate audio stream for a content
might be available.
Instead of going through transcription and translation of the original
audio stream, it may be preferrable for accuracy purposes to simply
transcribe the secondary audio stream.
This MR adds support for doing just that:
* Secondary audio sink pads can be requested as "sink_audio_%u"
* Sometimes audio source pads are added at that point to pass through
the audio, as "src_audio_%u"
* The main transcription bin now contains per-input stream transcription
bins. Those can be individually controlled through properties on the
sink pads, for instance translation-languages can be dynamically set
per audio stream
* Some properties that originally existed on the main element still
remain, but are now simply mapped to the always audio sink pad
* Releasing of secondary sink pads is nominally implemented, but not
tested in states other than NULL
An example launch line for this would be:
```
$ gst-launch-1.0 transcriberbin name=transcriberbin latency=8000 accumulate-time=0 \
cc-caps="closedcaption/x-cea-708, format=cc_data" sink_audio_0::language-code="es-US" \
sink_audio_0::translation-languages="languages, transcript=cc3"
uridecodebin uri=file:///home/meh/Music/chaplin.mkv name=d
d. ! videoconvert ! transcriberbin.sink_video
d. ! clocksync ! audioconvert ! transcriberbin.sink_audio
transcriberbin.src_video ! cea608overlay field=1 ! videoconvert ! autovideosink \
transcriberbin.src_audio ! audioconvert ! fakesink \
uridecodebin uri=file:///home/meh/Music/chaplin-spanish.webm name=d2 \
d2. ! audioconvert ! transcriberbin.sink_audio_0 \
transcriberbin.src_audio_0 ! fakesink
```
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1546 >
2024-04-25 11:56:01 +02:00
Seungha Yang
b3d3895ae7
cea608overlay: Fix black-background setting
...
Apply the property to newly created renderer
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1542 >
2024-04-15 15:38:31 +00:00
Philippe Normand
2341ee6935
dav1d: Set colorimetry parameters on src pad caps
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1514 >
2024-04-12 09:14:34 +00:00
Matthew Waters
4dcc44687a
cea608overlay: move Send impl lower in the stack
...
Try to avoid hiding another non-Send object in the State struct.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1519 >
2024-04-10 06:55:34 +00:00
Matthew Waters
fbce73f6fc
closedcaption: implement cea708overlay element
...
Can overlay any single CEA-708 service or any single CEA-608 channel.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1519 >
2024-04-10 06:55:34 +00:00
Matthew Waters
f0c38621c1
cea608overlay: also print bytes that failed to decode
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1519 >
2024-04-10 06:55:34 +00:00