Custom API that upstream elements can use to notify encoders about
marking longterm ref. pictures or using longterm ref. pictures in
encoding process.
This patch adds below properties:
long-term-ref: Enable/Disable dynamically marking long-term
reference pictures in encoding process
long-term-freq: Periodicity of long-term reference picture
marking in encoding process.
If a picture is marked as long-term reference picture then it remains
in the DPB list for ever unless it overrides with new long-term pitcure with
same index. Encoder can use this long-term picture as refence for
encoding.
This feature is mostly useful to avoid visual artifacts propagation in streaming use cases
when packet loss happens. Instead of requesting for IDR, client can request for use long-term
reference picture for encoding.
meson.build was both using path to gst-omx/openmax/OMX*
headers and path to OMX headers provided by tizilheaders.pc
so this patch makes sure we only use the later.
Also bump tizonia minimum version to 0.19.0 which
is the latest release.
We are operating in stream-format=byte-stream so the codec data buffer
is meant to be part of the buffer flow.
The base class will push it when a key frame is requested (as we stored
it with gst_video_encoder_set_headers()) but we still have to push it
right away as part of the normal buffer flow.
Also set the HEADER flag on this buffer.
We now negotiate subframe mode through the caps. To enabled subframe
mode, the caps need to specify alignment=nal:
... ! omxh264enc ! video/x-h264,alignment=nal ! ...
... ! omxh265enc ! video/x-h265,alignment=nal ! ...
By passing the expected video buffer layout, the upstream producer
may be able to produce buffers fitting those requierements allowing
gst-omx to use dynamic buffer mode rather than having to copy each input
buffer.
This is particularly useful with v4l2src as it can request the capture
driver to produce buffers with the required paddings.
Tell buffer consumer about our paddings.
v4l2src can now uses these paddings information when trying to import
buffers to configure the v4l2 driver accordingly.
Fixing a regression introduced in my previous patch
(7c40a91c31).
The ALLOCATION query needs to be handled by GstVideoEncoder (to call
propose_allocation()) so chain up the query handling rather than early
returning.
Ensure that the encoder releases all its input buffers when requested by
upstream. Encoder input buffers may be shared with downstreaming (when
using dmabuf), upstream may then request the encoder to
drain when reconfiguring before destroying its buffers.
Also drain on ALLOCATION query as we already do in kmssink as that
notify of a format change.
Fix "decoder ! encoder" pipeline when decoding a file with different
resolutions on Zynq.
When importing dmabuf from downstream, we want the allocator to be in
OTHER_POOL mode despite output_mode being DMABUF.
So check first if other_pool is set before checking for pool's
output_mode.
Those debug infos have proved to be very helpful when debugging
timestamp issues. They are often linked to gst-omx picking the wrong
frame when trying to map from OMX.
This means we can use some newer features and get rid of some
boilerplate code using the G_DECLARE_* macros.
As discussed on IRC, 2.44 is old enough by now to start depending on it.
One big restriction of the OMX buffer pool has always been
that the GstMemory objects were flagged with NO_SHARE.
This was because the buffer pool needed to be sure that when
a buffer returned to the pool, it would be safe to release the
OMX buffer back to OpenMAX.
With this change, this is no longer a restriction. What this
commit introduces is a new allocator that allows us to track
the GstMemory objects independently. Now, when a buffer returns
to the pool, it is not necessary for the memory to be released
as well. We simply track the memory's ref count in the allocator
and we return the OMX buffer back when the memory's ref count
drops to 0.
The reason for doing this is to allow implementing zero-copy
transfers in situations where we may need to copy or map a
certain region of the buffer. For instance, omxh264enc ! h264parse
should be possible to be zero-copy by using an OMX buffer pool
between them.
gst_memory_map() is already adding the offset to the mapped pointer.
Doing it in the memory implementation was resulting in the offset being
accounted twice.
It doesn't matter yet as we are only creating memory without offset for
now but it will once we'll start sharing OMX memories.
gstomx.c:1405:10: error: ‘OMX_IndexParamCustomContentPipe’ undeclared (first use in this function)
case OMX_IndexParamCustomContentPipe
Some enums have been deprecated in 1.2.0
https://gitlab.freedesktop.org/gstreamer/gst-omx/issues/27
gstomxvideoenc.c:2874:7: error: "USE_OMX_TARGET_ZYNQ_USCALE_PLUS" is not defined, evaluates to 0 [-Werror=undef]
#elif USE_OMX_TARGET_ZYNQ_USCALE_PLUS
Works on meson because it doesn't use -Wundef
This commit adds a .gitlab-ci.yml file, which uses a feature
to fetch the config from a centralized repository. The intent is
to have all the gstreamer modules use the same configuration.
The configuration is currently hosted at the gst-ci repository
under the gitlab/ci_template.yml path.
Part of https://gitlab.freedesktop.org/gstreamer/gstreamer-project/issues/29