Commit graph

113094 commits

Author SHA1 Message Date
Nicolas Dufresne
84daea6be2 v4l2codecs: h264: Reduce controls for subsequent slices
Only the SLICE_PARAMS and PRED_WEIGHTS are needed for the second and
following slices.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1624>
2021-03-02 22:03:34 +00:00
Ezequiel Garcia
1c082b79e1 v4l2codecs: h264: Implement optional scaling matrix
The new H.264 uAPI requires that all drivers support
scaling matrix only as an option, when a non-flat
scaling matrix is provided in the bitstream headers.

Take advantage of this and avoid passing the scaling
matrix if not needed.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1624>
2021-03-02 22:03:34 +00:00
Ezequiel Garcia
78756ecba9 v4l2codecs: h264: Only set SPS control if needed
Given V4L2 controls are cached in V4L2, there is no need
to set them if they don't change. Set the SPS control
only if a new sequence was received by the parser.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1624>
2021-03-02 22:03:34 +00:00
Ezequiel Garcia
ae9411e334 v4l2codecs: h264: Only slice-based need SLICE_PARAMS and PRED_WEIGHTS
Frame-based decoding mode doesn't require SLICE_PARAMS and
PRED_WEIGHTS controls.

Moreover, if the driver doesn't support these two controls, trying
to set them will fail. Fix this by only setting these on
slice-based decoding mode.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1624>
2021-03-02 22:03:34 +00:00
Ezequiel Garcia
010565eb7f v4l2codecs: h264: Add API checks
Check that the V4L2 H264 controls' sizes match
our expectation. If not, then probably there's an API
mismatch which will cause errors or decoding corruption.

Also, print a warning if the kernel version is too old.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1624>
2021-03-02 22:03:34 +00:00
Ezequiel Garcia
7d6b06ca1b v4l2codecs: h264: Update to the new uAPI
Starting from Linux v5.11, the V4L2 stateless H.264 uAPI
is updated and stable.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1624>
2021-03-02 22:03:34 +00:00
Ezequiel Garcia
56ecc19067 v4l2codecs: h264: Set the scaling matrix present flag unconditionally
We are currently always setting and passing a scaling matrix,
so need to set this flag accordingly. Passing a scaling matrix
optionally will be implemented in follow-up commit.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1624>
2021-03-02 22:03:34 +00:00
Víctor Manuel Jáquez Leal
f823124a39 va: postproc: mention the possibility of color balance
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2050>
2021-03-02 15:33:54 +00:00
Víctor Manuel Jáquez Leal
b61b3d833d docs: plugins update VA elements
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2050>
2021-03-02 15:33:54 +00:00
Víctor Manuel Jáquez Leal
c191a1a5da va: vp8dec, vp9dec: only set NV12 color format for documentation
Mention in documentation only the most used output format in VA-API.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2050>
2021-03-02 15:33:54 +00:00
Seungha Yang
96fd79cfc5 d3d11convert: Forward colorimetry and chroma-site from upstream
Adopt the improvement of https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1033
into d3d11.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2051>
2021-03-02 23:26:59 +09:00
Seungha Yang
6afb6e65fc d3d11convert: Add support for border drawing
... and fix wrong resizing when downstream requested PAR value

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2051>
2021-03-02 23:26:46 +09:00
Seungha Yang
82a4e7e773 d3d11convert: Prefer video processor over shader
... if video processor was used previously. Otherwise, switching
between video processor and shader would result in inconsistent
output image quality.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2051>
2021-03-02 23:10:47 +09:00
Seungha Yang
6ba1ee8d0f d3d11videoprocessor: Disable auto processing mode explicitly
Don't allow auto processing (e.g., denoising), as it might result
in unexpected output.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2051>
2021-03-02 23:10:47 +09:00
Seungha Yang
646c34794f d3d11memory: Fix for wrong texture_array_size returns
Fix mismatched return values

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2051>
2021-03-02 23:10:46 +09:00
Seungha Yang
47bcd62d1d d3d11decoder: Add trace log for DPB pool size debugging
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2051>
2021-03-02 23:10:46 +09:00
Seungha Yang
98929c8157 d3d11decoder: Always use render-target bind flag for downstream pool
To convert decoded texture into other format, downstream would use
video processor instead of shader. In order for downstream to
be able to use video processor even if we copied decoded texture
into downstream pool, we should set this bind flag. Otherwise,
downstream would keep switching video processor and shader
to convert format which would result in inconsistent image quality.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2051>
2021-03-02 23:10:46 +09:00
Seungha Yang
a4c6130477 d3d11: Fix wrong preprocessing blocks
Missed in https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/464

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2051>
2021-03-02 23:10:46 +09:00
Alexander Vandenbulcke
ccebcaa586 gl/dispmanx: assign render_rect to window before window_resize
If the `render_rect` for a dispmanx display is set after calling
`window_resize` the resize defaults to the dp_width and dp_height to
determine the location of the render rectangle instead of the correct
dimensions that should be set on the window_egl.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1056>
2021-03-02 09:13:25 +01:00
Mathieu Duponchelle
dd71f359be compositor: fix drawing of transparent background
When drawing the background multithreaded, y_start needs to be
scaled to obtain the correct byte offset from which to start
memsetting (yoffset).

Fixes #871

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1042>
2021-03-01 23:38:35 +00:00
He Junyan
f7eb93e22b va: vpp: fix a wrong caps logic in vpp_transform_caps().
The current gst_va_vpp_transform_caps return such as:
  video/x-raw(memory:VAMemory), width=(int)[ 16, 16384 ], height=(int)[ 16, 16384 ],
  interlace-mode=(string)progressive, format=(string){ NV12, I420, YV12, YUY2, RGBA,
  BGRA, P010_10LE, ARGB, ABGR, VUYA }; video/x-raw(memory:DMABuf), width=(int)[ 16,
  16384 ], height=(int)[ 16, 16384 ], interlace-mode=(string)progressive, format=(string)
  { NV12, I420, YV12, YUY2, RGBA, BGRA, P010_10LE, ARGB, ABGR, VUYA }; video/x-raw,
  width=(int)[ 16, 16384 ], height=(int)[ 16, 16384 ], interlace-mode=(string)progressive,
  format=(string){ VUYA, GRAY8, NV12, NV21, YUY2, UYVY, YV12, I420, P010_10LE };
  video/x-raw(memory:VAMemory), width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ],
  interlace-mode=(string)progressive; video/x-raw(memory:DMABuf), width=(int)[ 1, 2147483647 ],
  height=(int)[ 1, 2147483647 ], interlace-mode=(string)progressive; video/x-raw, width=(int)
  [ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], interlace-mode=(string)progressive

Which is not correct. It mixes the template caps and the input query caps together.
The correct way should be: clip the template caps with the input caps(remove format
and rangify size). The correct answer should be:
  video/x-raw(memory:VAMemory), width=(int)[ 16, 16384 ], height=(int)[ 16, 16384 ], interlace
  -mode=(string)progressive, format=(string){ NV12, I420, YV12, YUY2, RGBA, BGRA, P010_10LE,
  ARGB, ABGR, VUYA }; video/x-raw(memory:DMABuf), width=(int)[ 16, 16384 ], height=(int)[ 16,
  16384 ], interlace-mode=(string)progressive, format=(string){ NV12, I420, YV12, YUY2, RGBA,
  BGRA, P010_10LE, ARGB, ABGR, VUYA }; video/x-raw, width=(int)[ 16, 16384 ], height=(int)[ 16,
  16384 ], interlace-mode=(string)progressive, format=(string){ VUYA, GRAY8, NV12, NV21, YUY2,
  UYVY, YV12, I420, P010_10LE }

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2045>
2021-03-01 16:43:29 +00:00
Jan Alexander Steffens (heftig)
b9cc83ccf8 mpegtsparse: Fix switched DTS/PTS when set-timestamps=false
Fixes 30ee21eae3.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2047>
2021-03-01 16:29:58 +01:00
Ilya Kreymer
92626535c7 webrtc ice: Add 'min/max-rtp-port' props for setting RTP port range
default min port == 0, max port == 65535 -- if min port == 0, uses existing random port selection (range ignored)
add 'gathering_started' flag to avoid changing ports after gathering has started
validity checks: min port <= max port enforced, error thrown otherwise
include tests to ensure port range is being utilized (by @hhardy)

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/119>
2021-03-01 14:42:17 +00:00
Olivier Crête
3a3965e5cf webrtc ice: Only ever request one component, it's always rtcpmux
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/119>
2021-03-01 14:42:16 +00:00
Thibault Saunier
1d03fdcc09 transcoder: Add some missing API guards
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2044>
2021-03-01 12:37:44 +00:00
Thibault Saunier
d252ab2e06 transcoder: Fix potential use of uninitialized variables
gst_structure_get won't touch variables if the field is not present
leading to potential use of initialized vars

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2044>
2021-03-01 12:37:44 +00:00
Thibault Saunier
8c2fd4fff7 transcoder: Rework the API to create/get SignalAdapter
We can only have 1 single GstTranscoderSignalAdapter object for a
given GstTranscoder object, this enforces that by avoiding to expose
a constructor and instead add a method to GstTranscoder to get the
signal adapter (internally creating it when needed). We can still
cleanly ensure that the signal adapter is running for the requested
GMainContext and return NULL if it is not the case.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2044>
2021-03-01 12:37:44 +00:00
Matthew Waters
b6038523c1 webrtcbin: use regular ice nomination by default
1. We don't currently deal with an a=ice-options in the SDP which means
   we currently violate https://tools.ietf.org/html/rfc5245#section-8.1.1
   which states: "If its peer is using ICE options (present in
   an ice-options attribute from the peer) that the agent does not
   understand, the agent MUST use a regular nomination algorithm."
2. The recommendation is default to regular nomination in both RFC5245
   and RFC8445.  libnice change for this is
   https://gitlab.freedesktop.org/libnice/libnice/-/merge_requests/125
   which requires an API break in libnice.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2031>
2021-03-01 10:00:06 +00:00
Paul Goulpié
e1f6c37b46 gstvaapiencoder_h264: add ENCODER_EXPOSURE on aud propertie
forgot during the following mainline commit: bc2f8fd19e#

Signed-off-by: Paul Goulpié <paul.goulpie@ubicast.eu>
2021-02-27 22:48:57 +01:00
Philippe Normand
552007f839 transcoder: Remove un-needed gst_init call
We can safely assume GStreamer is already initialized from here.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1840>
2021-02-26 15:37:23 +00:00
Thibault Saunier
984f0c2d2f transcoder: Port to a GstBus API instead
Following the move made by GstPlayer in:

https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/35

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1840>
2021-02-26 15:37:23 +00:00
Thibault Saunier
7cf6e4d8f2 transcoder: Automatically generate enums GTypes
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1840>
2021-02-26 15:37:23 +00:00
Thibault Saunier
0a1dcc9546 transcoder: Port to G_DECLARE
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1840>
2021-02-26 15:37:23 +00:00
Thibault Saunier
a404417a0d symbols: Add GstTranscoderClass.parent_class
This is to work around https://github.com/hotdoc/hotdoc/pull/222
2021-02-26 11:55:27 -03:00
Thibault Saunier
be2353ba9a tutorials: Make basic-tutorial-2.py executable 2021-02-26 11:55:13 -03:00
Sebastian Dröge
02412620a8 decklinkvideosink: Use correct numerator for 29.97fps
It's not 0.2997fps.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2042>
2021-02-26 16:36:58 +02:00
Edward Hervey
6fe54f7f48 decklinksrc: Use a more accurate capture time
Use the hardware reference clock time when the frame was finished being captured
instead of a time much further down the road.

This improves the stability/accuracy of buffer times.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2040>
2021-02-26 14:08:43 +01:00
Stéphane Cerveau
a4b5d8bb60 meson: add uninstalled var for bash-completion
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/766>
2021-02-26 11:18:54 +01:00
Víctor Manuel Jáquez Leal
a9211a5067 va: allocator: No need of fourcc to create surface.
In commits 430aa327 and a119a940 there are a regression since it is
possible to create surfaces without fourcc, only chroma (rtformat) is
required.

This regression is shown on radeonsi driver with certain color
formats.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2035>
2021-02-25 12:05:19 +00:00
Víctor Manuel Jáquez Leal
87fe2e321e va: vpp: implement GstColorBalance interface
And modify multiple-vpp example to use it with -r parameter.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2033>
2021-02-25 11:22:53 +00:00
Víctor Manuel Jáquez Leal
5b117045e0 va: filter: add controllable and mutable playing to GParamFlags
Add controllable and mutable playgin to common GParamFlags.

Also use this common flags to video-direction

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2033>
2021-02-25 11:22:53 +00:00
Kristofer Björkström
11b5ebd058 gstrtspconnection: correct data_size when tunneled mode
gst_rtsp_connection_send_messages_usec in tunneled mode does base64
encode messages. When calculating data_size 1 bytes is added, which
results in ending the base64 with a NULL.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1051>
2021-02-25 12:21:53 +01:00
Jordan Petridis
bdbef0449c ci_template: build windows image in the ci
Build the images in the ci runners like we do,
for the linux containers.

Kudos to mesa for the powershell script that
reimplements the ci-templates behavior.

https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4304

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-ci/-/merge_requests/392>
2021-02-25 04:25:25 +02:00
Jordan Petridis
8f0481f19a docker/windows: make the powershell scripts more robust
Check the exit codes of various commands and fail
appropriatly upon error.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-ci/-/merge_requests/392>
2021-02-25 04:25:25 +02:00
Robert Rosengren
e99a6f3142 audio: Use GST_BUFFER_PTS instead of deprecated GST_BUFFER_TIMESTAMP
GST_BUFFER_PTS already used in audio code base (e.g. gstaudiodecoder),
so migrate completely from deprecated GST_BUFFER_TIMESTAMP for better
readability, as gstcompat.h defines GST_BUFFER_TIMESTAMP directly to PTS
anyway.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1048>
2021-02-25 02:04:44 +00:00
Jordan Petridis
1f0b3938af ci_template: use meson subproject --rebase for the windows builds as well
Similar to !375

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-ci/-/merge_requests/382>
2021-02-25 03:32:58 +02:00
Víctor Manuel Jáquez Leal
771645e445 vulkan: Fix elements long name.
Fix vkcoloconvert and vkviewconvert long names.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2034>
2021-02-24 20:15:52 +01:00
Sebastian Dröge
f5381ba9f5 audioaggregator: Log if the sample rate of one sinkpad is not accepted
Otherwise this can silently cause not-negotiated errors without any
direct hint about what went wrong.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1049>
2021-02-24 19:53:02 +02:00
Philipp Zabel
e885e0e1d7 v4l2videodec: fix src side frame rate negotiation
Negotiating v4l2h264dec ! v4l2h264enc transcoding pipelines fails in
case the encoder does not accept framerate=(fraction)0/1.
The acquired caps used for downstream negotiation are determined from
gst_v4l2_object_acquire_format(), which sets the GstVideoInfo::fps_n
and ::fps_d fields to 0.
To fix this, copy the frame rate from the sink side.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/882>
2021-02-24 17:15:49 +01:00
Guillaume Desmottes
3e27558095 miniobject: add GST_TYPE_MINI_OBJECT
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/764>
2021-02-24 13:13:07 +01:00