When the fifo is grown by exactly the current write offset, it would end
up with offset_w = nb_elems. If av_fifo_write_from_cb() is called in
such a state, the user callback would get callled with *nb_elems=0,
which will then cause the write to return without writing anything.
The ID3v2.4.0 standard defines TIT1 as the "Content group description"
tag [1]. This frame is usually referred to as the "Grouping" tag and in
de-facto use under that name by Vorbis and APEv2 [2].
This commit introduces a mapping from "TIT1" to "grouping" in the
id3v2.4 metadata conversion table. This will enable software to access
it using that name. In particular, MPD will now read this tag correctly
when using the ffmpeg decoder plugin.
[1] https://id3.org/id3v2.4.0-frames (4.2.1)
[2] https://picard-docs.musicbrainz.org/en/appendices/tag_mapping.html#grouping-3
Signed-off-by: Wolfgang Müller <wolf@oriole.systems>
Signed-off-by: Anton Khirnov <anton@khirnov.net>
We should use the systems crypto policy by default. If there is no
system policy, gnutls will use the "NORMAL" policy.
Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
Signed-off-by: Anton Khirnov <anton@khirnov.net>
The exif.h header doesn't use anything from tiff.h. We also just need
to include tiff_common.h in .c files where it actually used.
Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
bytestream.h should be directly included for GetByteContext and not
rely on other headers to include it. It could be removed from there.
Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
If a frame-threaded decoder with inter-frame dependencies
returns an error when decoding a frame and the returned frame
isn't clean, an error message is emitted claiming that this
is a bug. This seems to be based upon the thinking that
in this case a ThreadFrame has not been properly unreferenced.
Yet this is wrong, as decoders with inter-frame dependencies
don't use the frame for output for synchronization and therefore
don't use ThreadFrames at all for this. So unreferencing
this frame generically is fine and not a bug.
Reviewed-by: Anton Khirnov <anton@khirnov.net>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
The only unorthodox thing that this codec's init function does
is calling ff_get_format(). Yet this is supposed to be save,
as any get_format callback already has to deal with the scenario
of different AVCodecContext's calling it simultaneously.
Reviewed-by: Anton Khirnov <anton@khirnov.net>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Fixes build failures for videotoolbox
Signed-off-by: Limin Wang <lance.lmwang@gmail.com>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
The headers from version 3.7.1 are needed in order to support
parsing of frame properties. avs/version.h has been generated
as part of the AviSynth+ build process for a long time, but was
never installed with the includes until version 3.7.1a. Checking
for the presence of avs/version.h might have been sufficient,
but a version check mechanism might be useful in the future.
This does not change the version compatibility with the library
itself; previous 3.x versions of AviSynth+ as well as AviSynth 2.6
can still be used with the demuxer.
Signed-off-by: Stephen Hutchinson <qyot27@gmail.com>
* Field Order
* Chroma Location
* Color Transfer Characteristics
* Color Range
* Color Primaries
* Matrix Coefficients
The existing TFF/BFF detection is retained as a fallback for
older versions of AviSynth that can't access frame properties.
The other properties have no legacy equivalent to detect them.
Signed-off-by: Stephen Hutchinson <qyot27@gmail.com>
AviSynth works on frame-based video by default, which can
be either progressive or interlaced. Some filters can break
frames into half-height fields, at which point it considers
the clip to be field-based (avs_is_field_based can be used
to check for this situation).
To properly detect the field order of a typical video clip,
the frame needs to have been weaved back together already,
so avs_is_field_based should actually report 'false' when
checked.
Signed-off-by: Stephen Hutchinson <qyot27@gmail.com>
It is only used by the H.264 decoder (as well as the dirac decoder,
which already uses a local copy).
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Seems to have been always unused since these functions were introduced
in 1f0cd30fd9.
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This piece of code has been added in an already commented-out state
in commit 158c7f059c. It certainly
doesn't make sense now (if ever) because new_picture_ptr it used
has been removed in 6571e41dcd
(and new_picture is only used for encoding).
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
mpegvideo-based encoders supporting bframes implement this
by opening encoders of their own to test how long the chains
of bframes are supposed to be. The needed AVCodec was obtained
via avcodec_find_encoder(). This is complicated, as the current
encoder can be directly obtained. And it also is not guaranteed
that one actually gets the current encoder or not another encoder
for the same codec ID (the latter does not seem to be the case now).
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>