Víctor Manuel Jáquez Leal
72ab56c376
va: allocator: free allocator when a mem is held
...
An application, using for example appsink, can hold buffers from any
va allocator after setting the pipeline to NULL. We need to destroy
the allocator when that memory is unrefed.
This patch juggles a bit with the allocator reference count in
memories in order to achieve this:
1. When memory is created no alloc ref is modified
2. When memory is released, alloc ref is decreased
3. When memory is reassiged to a buffer, alloc ref is increased
4. When memory is flushed, alloc ref is increased becase it is going
to be decreased in gst_memory_unref()
Also this patch moves the deallocation of member variables to
finalize() rather than dispose()
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1815 >
2020-11-24 12:44:24 +01:00
Víctor Manuel Jáquez Leal
ba4442a29d
va: allocator: dmabuf: initialize cond
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1815 >
2020-11-24 12:44:24 +01:00
Olivier Crête
a801018ef1
webrtc: Make ssrc map into separate data structures
...
They now contain a weak reference and that could be freed later
causing strange crashes as GWeakRef are not movable.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1766 >
2020-11-24 04:27:52 +00:00
Olivier Crête
1deb034e3d
webrtcstats: Get the remote-inbound stats from the right RTPSource
...
This also means that we need to get the clock-rate from the codec instead
of from the RTPSource, as the remote one doesn't include a clock rate.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1766 >
2020-11-24 04:27:52 +00:00
Olivier Crête
1c1661b54f
webrtcbin: Implement getting stats for a specific pad
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1766 >
2020-11-24 04:27:52 +00:00
Olivier Crête
23ea950351
webrtcstats: Also return the raw rtpsource stats for more information
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1766 >
2020-11-24 04:27:52 +00:00
Olivier Crête
b895240241
webrtcstats: Avoid copy of GstStructure
...
Instead transfer the ownership to the new structure
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1766 >
2020-11-24 04:27:52 +00:00
Olivier Crête
a46c6e3a97
webrtcstats: Remove receiver side when sending
...
Those are just invalid and just reflect what we sent. We'd need to parse the
RTCP XR packets from the other side to know more about those.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1766 >
2020-11-24 04:27:52 +00:00
Olivier Crête
ba0dfa52d2
webrtcstats: Extract statistics from the rtpjitterbuffer
...
And expose them as standardised webrtc statistics
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1766 >
2020-11-24 04:27:52 +00:00
Olivier Crête
fc0f6db856
webrtcbin: Store the rtpjitterbuffer instances to extract stats from them
...
Store them as web refs to avoid having to worry about freeing later and because
the new-jitterbuffer is on a different thread
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1766 >
2020-11-24 04:27:52 +00:00
Olivier Crête
d9d7814182
webrtcstats: Document all RTP missing fields according to the latest spec
...
Just document all the missing fields and document which ones will never
be implemented because they depend on the codec or depayloader
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1766 >
2020-11-24 04:27:52 +00:00
Olivier Crête
895ea210c2
webrtcstats: RTCP computed RTT is only available at sender
...
The receiver doesn't have the information to compute it.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1766 >
2020-11-24 04:27:52 +00:00
Olivier Crête
a5c3331197
webrtcstats: Remove redundant lines
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1766 >
2020-11-24 04:27:52 +00:00
Olivier Crête
52c676546d
webrtc: Also remove rtcp_transport from the structure
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1765 >
2020-11-24 01:59:55 +00:00
Olivier Crête
c5d76d944e
webrtc: Remove APIs to set transport on sender/receiver
...
They're not not used ever.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1765 >
2020-11-24 01:59:55 +00:00
Olivier Crête
5d5417f271
webrtc: Remove non rtcp-mux code
...
RTCP mux is now always required by the WebRTC spec
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1765 >
2020-11-24 01:59:55 +00:00
Julian Bouzas
64f96facca
nvcodec: Assume 25fps if framerate is invalid when calculating latency
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1826 >
2020-11-23 18:27:43 +00:00
Víctor Manuel Jáquez Leal
1a5862dd39
codecs: h264decoder: fix memory leak
...
gst_h264_dbp_get_picture_all() returns a full transfer of the GArray, which
needs be unrefed. But it is not unrefed in
gst_h264_decoder_find_first_field_picture() leaking it.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1827 >
2020-11-23 15:23:35 +01:00
Edward Hervey
1749dc66c5
mpegts: Documentation fixes
...
gtk-doc was complaining :)
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1825 >
2020-11-21 08:58:43 +00:00
Tim-Philipp Müller
470c79be61
qroverlay: unset executable flag on source files
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1824 >
2020-11-20 13:24:24 +00:00
Tim-Philipp Müller
53947cad29
qroverlay: fix auto detection of json-glib for plugin
...
Only want to check for json-glib when libqrencode was found,
but also it shouldn't be required but depend on the option.
Fixes #1465
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1824 >
2020-11-20 13:22:48 +00:00
Seungha Yang
d1e7290109
d3d11: Add support for packed 4:2:2 and 4:4:4 10bits formats
...
Add support for Y210 and Y410 formats which are commonly used format
for en/decoders on Windows. Note that those formats cannot be used for
render target (output) of shader.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1821 >
2020-11-20 02:28:54 +09:00
Olivier Crête
03d710bd40
openh264dec: Accept constrained-high and progressive-high profiles
...
They're just subsets of the high profile.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1634 >
2020-11-18 15:47:36 -05:00
Olivier Crête
f83039531e
d3d11h264dec: Accept constrained-high and progressive-high profiles
...
They're just subsets of the high profile.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1634 >
2020-11-18 15:47:34 -05:00
Olivier Crête
e17e88e033
msdkh264dec: Accept constrained-high and progressive-high profiles
...
They're just subsets of the high profile.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1634 >
2020-11-18 15:46:52 -05:00
Olivier Crête
e53da20938
nvdec: Accept progressive-high and contrained-high profiles
...
They're subsets of the high profiles with no interlacing and
no B-frames for constrained
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1634 >
2020-11-18 15:46:52 -05:00
He Junyan
33fcb0faf0
codecparsers: av1: add the set_operating_point() API.
...
The av1 can support multi layers when scalability is enabled. We
need an API to set the operating point and filter the OBUs just
belonging to some layers(the layers are specified by the operating
point).
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1464 >
2020-11-17 19:31:09 +00:00
He Junyan
c4aaeb0509
codecparsers: av1: Add an API to reset the annex_b state only.
...
In practice, we encounter streams that have one or more temporal units
error. When that kind of error temporal units is in annex b format, the
whole temporal unit should be discarded.
But the temporal units before it are correct and can be used. More
important, because of the error temporal unit, the parser is in a wrong
state and all later temporal unit are also parsed uncorrectly.
We need to add this API to reset the annex_b state only when we meet
some temporal unit error.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1464 >
2020-11-17 19:31:09 +00:00
He Junyan
a4f459fe21
codecparsers: av1: clean the seen_frame_header in parse_tile_group().
...
The current seen_frame_header is not cleaned correctly. According
to the spec, it should be cleaned when tiles are parsed completely.
Also delete a verbose seen_frame_header init in reset_state().
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1464 >
2020-11-17 19:31:09 +00:00
He Junyan
6dedbc30c5
codecparsers: av1: fix a typo in parse_metadata_scalability
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1464 >
2020-11-17 19:31:09 +00:00
He Junyan
227d7a9327
codecparsers: av1: Do not assert in identify_one_obu when check annex b size.
...
Some buggy stream just writes the wrong temporal unit and frame size in
the stream. We should return failure rather than assert to abort.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1464 >
2020-11-17 19:31:09 +00:00
He Junyan
b511761f70
codecparsers: av1: Add unknow AV1 profile define for saint check.
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1464 >
2020-11-17 19:31:09 +00:00
He Junyan
0d4982a3d5
codecparsers: av1: Improve the parse_tile_info.
...
1. store more tile info when parse tile group.
The column, row, tile offset and tile data size are all useful for
decoder process, especially for HW kind decoder such as VAAPI dec.
Also fix the tile group skip size for each tile data.
2. No min_inner_tile_width requirement in newest spec.
3. Calculate the sbs of each tile for both uniform tile and non-uniformi
tile.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1464 >
2020-11-17 19:31:09 +00:00
He Junyan
da0584010c
codecparsers: av1: Fix a tile info read typo in frame header.
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1464 >
2020-11-17 19:31:09 +00:00
He Junyan
26567354b9
codecparsers: av1: Fix a typo when get value of segmentation params.
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1464 >
2020-11-17 19:31:09 +00:00
He Junyan
2fd1da60ea
codecparsers: av1: add valid check for global motion params.
...
The global motion params and its matrix values need to be verified
before we use them. If it is invalid, we should notify the decoder
that it should not be used.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1464 >
2020-11-17 19:31:09 +00:00
He Junyan
8f55c9d6d2
codecparsers: av1: uint8 range is not enough for av1_bitstreamfn_ns
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1464 >
2020-11-17 19:31:09 +00:00
He Junyan
900bd06939
codecparsers: av1: delete duplicated GST_AV1_GM_ABS_ALPHA_BITS define.
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1464 >
2020-11-17 19:31:09 +00:00
He Junyan
12af439c58
test: av1parser: update the test result because of bug fixing.
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1464 >
2020-11-17 19:31:09 +00:00
He Junyan
fce380ec40
codecparsers: av1: Improve the loop filter setting.
...
1. loop_filter_ref_deltas should be int because it needs to compare
with 0.
2. Move the loop filter init logic to setup_past_independence() and
load_previous(), which make it more precise with the spec.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1464 >
2020-11-17 19:31:09 +00:00
He Junyan
f20798a1db
codecparsers: av1: Fix a error report for metadata obu.
...
The metadata OBUs, for example, ITUT_T35 has an undefined payload such
as itu_t_t35_payload_bytes field in AV1 spec, which may cause the failure
of parsing the trailings bits. We can give a warning and ignore this kind
of errors.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1464 >
2020-11-17 19:31:09 +00:00
He Junyan
2c3a33eeab
codecparsers: av1: Fix a level index bug in sequence.
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1464 >
2020-11-17 19:31:09 +00:00
He Junyan
7e33863b10
codecparsers: av1: all ref idx should be gint8.
...
All the ref index need to compare with 0 in reference index decision
algorithm. We also need to init them to -1.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1464 >
2020-11-17 19:31:09 +00:00
Seungha Yang
483768cfa7
va: h264dec: Add support for interlaced stream
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1812 >
2020-11-17 20:20:32 +09:00
Víctor Manuel Jáquez Leal
eadda27dde
va: h264dec: implement gst_va_h264_dec_new_field_picture()
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1812 >
2020-11-17 19:57:35 +09:00
Seungha Yang
215835b201
va: h264dec: Fix picture_height_in_mbs_minus1
...
Fix for interlaced stream (when sps->frame_mbs_only_flag is equal to one)
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1812 >
2020-11-17 19:57:35 +09:00
Víctor Manuel Jáquez Leal
a9ae00a2c1
va: h264dec: admit baseline if stream obeys A.2
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1812 >
2020-11-17 19:57:35 +09:00
Seungha Yang
64ea751cd2
codecs: h264decoder: Add support for field ref picture list modification
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1812 >
2020-11-17 19:57:30 +09:00
Seungha Yang
88ebe8031a
codecs: h264decoder: Add more option arguments for reference picture getter
...
In case that "pic_order_cnt_type" is equal to zero, ref picture
list for B slice should not include non-existing picture
as per spec 8.2.4.2.3. And, the second field is not needed
for the process of frame picture reference list construction
since it needs to be frame unit, not field picture in that case.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1812 >
2020-11-17 19:44:04 +09:00
Seungha Yang
e1adc572a7
codecs: h264decoder: Split gap picture as well if needed
...
field pair pictures might be required for reference list
depending on context.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1812 >
2020-11-17 19:08:47 +09:00