History

avcodec: remove deprecated FF_API_AVCODEC_CLOSE

Deprecated since 2024-02-09.

James Almer committed 1 year ago

Commit 0d48da21 parent 82243273 files · +0 −27Browse files

Unified · Split

3 files
  1. libavcodec/avcodec.c +0 −8
  2. libavcodec/avcodec.h +0 −18
  3. libavcodec/version_major.h +0 −1
libavcodec/avcodec.c+0−8
@@ -493,14 +493,6 @@ av_cold void ff_codec_close(AVCodecContext *avctx) · 492 unmodified lines
493 avctx->active_thread_type = 0;493 avctx->active_thread_type = 0;
494}494}
495 495
496#if FF_API_AVCODEC_CLOSE
497int avcodec_close(AVCodecContext *avctx)
498{
499 ff_codec_close(avctx);
500 return 0;
501}
502#endif
503
504static const char *unknown_if_null(const char *str)496static const char *unknown_if_null(const char *str)
505{497{
506 return str ? str : "unknown";498 return str ? str : "unknown";
libavcodec/avcodec.h+0−18
@@ -2234,24 +2234,6 @@ int avcodec_parameters_to_context(AVCodecContext *codec, · 2233 unmodified lines
2234 */2234 */
2235int avcodec_open2(AVCodecContext *avctx, const AVCodec *codec, AVDictionary **options);2235int avcodec_open2(AVCodecContext *avctx, const AVCodec *codec, AVDictionary **options);
2236 2236
2237#if FF_API_AVCODEC_CLOSE
2238/**
2239 * Close a given AVCodecContext and free all the data associated with it
2240 * (but not the AVCodecContext itself).
2241 *
2242 * Calling this function on an AVCodecContext that hasn't been opened will free
2243 * the codec-specific data allocated in avcodec_alloc_context3() with a non-NULL
2244 * codec. Subsequent calls will do nothing.
2245 *
2246 * @deprecated Do not use this function. Use avcodec_free_context() to destroy a
2247 * codec context (either open or closed). Opening and closing a codec context
2248 * multiple times is not supported anymore -- use multiple codec contexts
2249 * instead.
2250 */
2251attribute_deprecated
2252int avcodec_close(AVCodecContext *avctx);
2253#endif
2254
2255/**2237/**
2256 * Free all allocated data in the given subtitle struct.2238 * Free all allocated data in the given subtitle struct.
2257 *2239 *
libavcodec/version_major.h+0−1
@@ -39,7 +39,6 @@ · 38 unmodified lines
39 39
40#define FF_API_INIT_PACKET (LIBAVCODEC_VERSION_MAJOR < 62)40#define FF_API_INIT_PACKET (LIBAVCODEC_VERSION_MAJOR < 62)
41 41
42#define FF_API_AVCODEC_CLOSE (LIBAVCODEC_VERSION_MAJOR < 62)
43#define FF_API_BUFFER_MIN_SIZE (LIBAVCODEC_VERSION_MAJOR < 62)42#define FF_API_BUFFER_MIN_SIZE (LIBAVCODEC_VERSION_MAJOR < 62)
44#define FF_API_VDPAU_ALLOC_GET_SET (LIBAVCODEC_VERSION_MAJOR < 62)43#define FF_API_VDPAU_ALLOC_GET_SET (LIBAVCODEC_VERSION_MAJOR < 62)
45#define FF_API_QUALITY_FACTOR (LIBAVCODEC_VERSION_MAJOR < 62)44#define FF_API_QUALITY_FACTOR (LIBAVCODEC_VERSION_MAJOR < 62)

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t