diff mbox series

[FFmpeg-devel,v2,06/33] avcodec/avcodec: Remove AV_CODEC_FLAG2_DROP_FRAME_TIMECODE

Message ID 20230204104204.20721-7-anton@khirnov.net
State New
Headers show
Series [FFmpeg-devel,v2,01/33] avformat/avformat: Remove AVOutputFormat.data_codec | expand

Checks

Context Check Description
yinshiyou/configure_loongarch64 warning Failed to apply patch
andriy/configure_x86 warning Failed to apply patch

Commit Message

Anton Khirnov Feb. 4, 2023, 10:41 a.m. UTC
From: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>

It has been deprecated in 94d68a41fabb55dd8c7e59b88fe4a28a637d1e5f
and can't be set via AVOptions. The only codecs that use it
(the MPEG-1/2 encoders) have private options for this.
So remove it.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Signed-off-by: Anton Khirnov <anton@khirnov.net>
---
 libavcodec/avcodec.h   | 5 -----
 libavcodec/mpeg12enc.c | 1 -
 2 files changed, 6 deletions(-)
diff mbox series

Patch

diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h
index b9bd69a2ec7..d8f22f58007 100644
--- a/libavcodec/avcodec.h
+++ b/libavcodec/avcodec.h
@@ -343,11 +343,6 @@  typedef struct RcOverride{
  */
 #define AV_CODEC_FLAG2_LOCAL_HEADER   (1 <<  3)
 
-/**
- * timecode is in drop frame format. DEPRECATED!!!!
- */
-#define AV_CODEC_FLAG2_DROP_FRAME_TIMECODE (1 << 13)
-
 /**
  * Input bitstream might be truncated at a packet boundaries
  * instead of only at frame boundaries.
diff --git a/libavcodec/mpeg12enc.c b/libavcodec/mpeg12enc.c
index b5951e43070..26cf33a3c68 100644
--- a/libavcodec/mpeg12enc.c
+++ b/libavcodec/mpeg12enc.c
@@ -249,7 +249,6 @@  static av_cold int encode_init(AVCodecContext *avctx)
         }
     }
 
-    mpeg12->drop_frame_timecode = mpeg12->drop_frame_timecode || !!(avctx->flags2 & AV_CODEC_FLAG2_DROP_FRAME_TIMECODE);
     if (mpeg12->drop_frame_timecode)
         mpeg12->tc.flags |= AV_TIMECODE_FLAG_DROPFRAME;
     if (mpeg12->drop_frame_timecode && mpeg12->frame_rate_index != 4) {