... and various code cleanup.
* Move spreaded decoding API calls into one method
Previously, decoding flow of most codecs are
- Call DecoderBeginFrame() on start_picture()
- Call {Get,Release}DecoderBuffer() on decode_slice()
- Call SubmitDecoderBuffers() and DecoderEndFrame() on end_picture()
Such spreaded API calls make it hard to keep track of status
of decoding. Now it will be done at once in a new method.
* Drop a code for non-zero wBadSliceChopping
When bitstream buffer provided by driver is not sufficient
to write compressed bitstream data, host decoder needs to make use
of wBadSliceChopping so that driver can understand there are
multiple bitstream buffer. But it's a bit unrealistic and
not tested. Since FFMpeg's DXVA implemetaion doesn't support it,
we might be able to ignore the case for now.
* Make code more portable
Consider common logic of GstCodecs -> DXVA translation for all D3D APIs
(i,e., D3D9, D3D11, and D3D12).
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2525>
Skip the closedcaption element tests if the
closedcaption option is disabled at compile
time (i.e. -Dclosedcaption=disabled).
v2: rename pangocairo_dep to avoid conflict
with later definition in ext/ttml/meson.build
as suggested by @tpm.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1388>
The max_num_reorder_frames number can change the way we bumping the
pictures in the DPB. The smaller it is, the lower latency we will
get. So it is important for live mode streams, but it is not given
in VUI parameters sometimes. We now improve the policy to infer it:
1. Never guess it in the "strict" compliance.
2. For baseline and constrained baseline profiles, which do not have
B frames, set it to 0.
3. For -intra only profiles, set it to 0.
4. Otherwise, not guess it.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2501>
In ext/aes/meson.build, the aes_dep will return
not-found if -Daes=disabled, regardless of whether
openssl is found or not. Thus, we don't need a
separate check for the option. This will also
ensure that aes_dep is always defined and we can
use it in the tests/check/meson.build unit.
Fixes#1660
v2: handle -Daes=disabled, too.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2522>
In the h264, the Baseline profile is widely misused. A lot of streams declare
that they are the Baseline, but in fact they just conform to ConstrainedBaseline.
The features such as FMO and ASO are not used at all.
If the decoder does not strictly conforms to the SPEC, we can just use Baseline
or Main profile to decode it to avoid lots of streams failure.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2428>
We control the policy of fast bump by the profile and the compliance
property. For baseline and constrained baseline profiles, we can use
more radical bump policy. User can also change the bump policy by
setting the compliance property in run time.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2432>
Some features such as the low-latency DPB bumping and mapping the
baseline profile as the constrained-baseline profile do not conform
to the H264 offical spec. But in practice, they are very useful and
are widely needed. We add this compliance property to control the
behavior of the decoder, make it fit more requirement.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2432>
In order to install the color balance interface, a GstVaFilter is
instantiated and queried to know if it supports color balance
filter. It was done just after the GObject was registered. Now, it's
done before.
The reason of this change is that deinterlace element has to be
registered only if deinterlace filter is available, using only one
instantiate of GstVaFilter.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2495>
Having an unlimited input queue is very bad if the
encoder can't run at real-time. Eventually it will
consume all RAM. I don't really see any reason to
have more than 1 outstanding encoded frame, so
remove the queue and limit things to 1 pending frame.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2499>
There was a race when going to PAUSED while pushing a buffer to the
pipeline process (where we weren't even cancelling anything).
This rework base all the cancellation around the GCancellable
"cancelled" signal trying to ensure that the streaming thread will not
block once a cancel operation happens.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2504>
During the output process, if there are multiple frames in a TU (i.e. multi-spatial
layers case), only one frame with the highest spatial layer id should be selected
according to av1 spec. The highest spatial layer id is obtained from idc value of
the operating point.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2475>
Commit bc09d8cc changed gstmpdparser to put the entire
<ContentProtection> element in the "value" field, so that DRMs
other than PlayReady could make use of the data inside this
element.
However, the data in the "value" field does not include any
XML namespace declarations that are used within the element. This
causes problems for a namespace aware XML parser that wants to
make use of this data.
This commit modifies the way the XML is converted to a string
so that XML namespaces are preserved in the output.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2487>
Some closedcaption elements like sccenc except input buffers
to have timecode metas. The original use case is to serialize
closed captions extracted from a video stream, in that case
ccextractor copies the video time code metas to the closed
caption buffers, but no such mechanism exists when creating
a CC stream ex nihilo.
Remedy that by having timecodestamper accept closedcaption
input caps, as long as they have a framerate.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2490>