]> git.sesse.net Git - ffmpeg/commitdiff
avcodec: Remove sidedata-only-packet cruft
authorAndreas Rheinhardt <andreas.rheinhardt@gmail.com>
Thu, 25 Feb 2021 17:01:14 +0000 (18:01 +0100)
committerJames Almer <jamrial@gmail.com>
Tue, 27 Apr 2021 13:42:59 +0000 (10:42 -0300)
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
libavcodec/avcodec.h
libavcodec/flacenc.c
libavcodec/options_table.h
libavcodec/version.h

index 5e6967df0db35ab8e98d55deac9a748834031460..b46b858416401580df65229950879122c31105c9 100644 (file)
@@ -2029,21 +2029,6 @@ typedef struct AVCodecContext {
     uint64_t vbv_delay;
 #endif
 
-#if FF_API_SIDEDATA_ONLY_PKT
-    /**
-     * Encoding only and set by default. Allow encoders to output packets
-     * that do not contain any encoded data, only side data.
-     *
-     * Some encoders need to output such packets, e.g. to update some stream
-     * parameters at the end of encoding.
-     *
-     * @deprecated this field disables the default behaviour and
-     *             it is kept only for compatibility.
-     */
-    attribute_deprecated
-    int side_data_only_packets;
-#endif
-
     /**
      * Audio only. The number of "priming" samples (padding) inserted by the
      * encoder at the beginning of the audio. I.e. this number of leading
index 05a85d830fe0b98f5e4726b8178d8b22250c443c..38571ec9c9940bc2a7dfa5899b4ad78f0c2d9bc0 100644 (file)
@@ -1370,13 +1370,7 @@ static int flac_encode_frame(AVCodecContext *avctx, AVPacket *avpkt,
         av_md5_final(s->md5ctx, s->md5sum);
         write_streaminfo(s, avctx->extradata);
 
-#if FF_API_SIDEDATA_ONLY_PKT
-FF_DISABLE_DEPRECATION_WARNINGS
-        if (avctx->side_data_only_packets && !s->flushed) {
-FF_ENABLE_DEPRECATION_WARNINGS
-#else
         if (!s->flushed) {
-#endif
             uint8_t *side_data = av_packet_new_side_data(avpkt, AV_PKT_DATA_NEW_EXTRADATA,
                                                          avctx->extradata_size);
             if (!side_data)
index e12159f734514f83297c01c101f0dd3d596f5222..956132437a071504dc47f6c4fe182cc291101236 100644 (file)
@@ -444,9 +444,6 @@ static const AVOption avcodec_options[] = {
 #if FF_API_OLD_ENCDEC
 {"refcounted_frames", NULL, OFFSET(refcounted_frames), AV_OPT_TYPE_BOOL, {.i64 = 0}, 0, 1, A|V|D },
 #endif
-#if FF_API_SIDEDATA_ONLY_PKT
-{"side_data_only_packets", NULL, OFFSET(side_data_only_packets), AV_OPT_TYPE_BOOL, { .i64 = 1 }, 0, 1, A|V|E },
-#endif
 {"apply_cropping", NULL, OFFSET(apply_cropping), AV_OPT_TYPE_BOOL, { .i64 = 1 }, 0, 1, V | D },
 {"skip_alpha", "Skip processing alpha", OFFSET(skip_alpha), AV_OPT_TYPE_BOOL, {.i64 = 0 }, 0, 1, V|D },
 {"field_order", "Field order", OFFSET(field_order), AV_OPT_TYPE_INT, {.i64 = AV_FIELD_UNKNOWN }, 0, 5, V|D|E, "field_order" },
index a53ed233f267495fd76d01cecbb8910eb13203f9..a6b6ffc799d4097d60c6ec35fd95e6144dc907a4 100644 (file)
@@ -54,9 +54,6 @@
 #ifndef FF_API_CODED_FRAME
 #define FF_API_CODED_FRAME       (LIBAVCODEC_VERSION_MAJOR < 59)
 #endif
-#ifndef FF_API_SIDEDATA_ONLY_PKT
-#define FF_API_SIDEDATA_ONLY_PKT (LIBAVCODEC_VERSION_MAJOR < 59)
-#endif
 #ifndef FF_API_VDPAU_PROFILE
 #define FF_API_VDPAU_PROFILE     (LIBAVCODEC_VERSION_MAJOR < 59)
 #endif