Commit graph

10 commits

Author SHA1 Message Date
He Junyan 075937dc19 va: vp9enc: Avoid reopen encoder or renegotiate
If parameters remain similar enough to avoid either encoder reopening
or downstream renegotiation, avoid it.

This is going to be useful for dynamic parameters setting.

To check if the stream parameters changed, so the internal encoder has
to be closed and opened again, are required two steps:

1. If input caps, format, profile, chroma or rate control mode have changed.
2. If any of the calculated variables and element properties have changed.

Later on, only if the output caps also changed, the pipeline
is renegotiated.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6441>
2024-04-02 09:06:07 +00:00
He Junyan e023546162 va: encoder: Fix the unit of bitrate in debug log message
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6483>
2024-04-01 15:39:13 +00:00
He Junyan 9c3bd3950e va: vp9enc: Adjust the coded buffer size to avoid failure
Some extreme case such as "videotestsrc pattern=1" can generate pure
white noise videoes, for which encoder may generate too big output
for current coded buffer size. We now consider the qindex and bitrate
to avoid that.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6483>
2024-04-01 15:39:13 +00:00
He Junyan 2560f4c581 va: vp9enc: Fix the frame size not enough issue for super frame
The current code forgets to add the current last frame size into
the total super frame size.

Fixes: #3427
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6483>
2024-04-01 15:39:13 +00:00
He Junyan a170fa4f46 va: {av1, vp9}enc: Use g_free() to free frames
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6466>
2024-03-28 16:29:50 +08:00
He Junyan 7ac9d26533 va: vp9enc: Correct the flags for registering properties
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6437>
2024-03-27 10:24:12 +08:00
He Junyan 73c1c1fe7f va: {vp9, av1}enc: Do not use g_slice_new() to create frames
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6437>
2024-03-27 10:18:04 +08:00
He Junyan 71eff7ce97 va: encoder: update the bitrate change correctly
We should update and notify the bitrate change at a common place,
no matter whether the bitrate is calculated or not.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6433>
2024-03-26 18:15:20 +00:00
He Junyan 5c51abfa71 va: vp9enc: enable ICQ and QVBR modes
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6433>
2024-03-26 18:15:20 +00:00
He Junyan 3b57825ca6 va: Implement the vavp9enc plugin
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3293>
2024-03-20 08:53:11 +00:00