mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-12-16 03:50:05 +01:00
Merge commit '7950e519bb094897f957b9a9531cc60ba46cbc91'
* commit '7950e519bb094897f957b9a9531cc60ba46cbc91': Disable deprecation warnings for cases where a replacement is available Conflicts: libavcodec/avpacket.c libavcodec/pthread.c libavcodec/utils.c libavdevice/v4l2.c libavfilter/avfiltergraph.c libavfilter/buffersrc.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
@@ -34,6 +34,7 @@
|
||||
#include "libavutil/channel_layout.h"
|
||||
#include "libavutil/crc.h"
|
||||
#include "libavutil/frame.h"
|
||||
#include "libavutil/internal.h"
|
||||
#include "libavutil/mathematics.h"
|
||||
#include "libavutil/pixdesc.h"
|
||||
#include "libavutil/imgutils.h"
|
||||
@@ -630,7 +631,9 @@ int avcodec_default_get_buffer2(AVCodecContext *avctx, AVFrame *frame, int flags
|
||||
return ret;
|
||||
|
||||
#if FF_API_GET_BUFFER
|
||||
FF_DISABLE_DEPRECATION_WARNINGS
|
||||
frame->type = FF_BUFFER_TYPE_INTERNAL;
|
||||
FF_ENABLE_DEPRECATION_WARNINGS
|
||||
#endif
|
||||
|
||||
switch (avctx->codec_type) {
|
||||
@@ -701,6 +704,7 @@ int ff_init_buffer_info(AVCodecContext *avctx, AVFrame *frame)
|
||||
}
|
||||
|
||||
#if FF_API_GET_BUFFER
|
||||
FF_DISABLE_DEPRECATION_WARNINGS
|
||||
int avcodec_default_get_buffer(AVCodecContext *avctx, AVFrame *frame)
|
||||
{
|
||||
return avcodec_default_get_buffer2(avctx, frame, 0);
|
||||
@@ -724,6 +728,7 @@ static void compat_release_buffer(void *opaque, uint8_t *data)
|
||||
AVBufferRef *buf = opaque;
|
||||
av_buffer_unref(&buf);
|
||||
}
|
||||
FF_ENABLE_DEPRECATION_WARNINGS
|
||||
#endif
|
||||
|
||||
static int get_buffer_internal(AVCodecContext *avctx, AVFrame *frame, int flags)
|
||||
@@ -740,6 +745,7 @@ static int get_buffer_internal(AVCodecContext *avctx, AVFrame *frame, int flags)
|
||||
return ret;
|
||||
|
||||
#if FF_API_GET_BUFFER
|
||||
FF_DISABLE_DEPRECATION_WARNINGS
|
||||
/*
|
||||
* Wrap an old get_buffer()-allocated buffer in an bunch of AVBuffers.
|
||||
* We wrap each plane in its own AVBuffer. Each of those has a reference to
|
||||
@@ -852,6 +858,7 @@ fail:
|
||||
av_buffer_unref(&dummy_buf);
|
||||
return ret;
|
||||
}
|
||||
FF_ENABLE_DEPRECATION_WARNINGS
|
||||
#endif
|
||||
|
||||
ret = avctx->get_buffer2(avctx, frame, flags);
|
||||
@@ -1446,7 +1453,9 @@ int ff_alloc_packet2(AVCodecContext *avctx, AVPacket *avpkt, int size)
|
||||
if (avpkt->data) {
|
||||
AVBufferRef *buf = avpkt->buf;
|
||||
#if FF_API_DESTRUCT_PACKET
|
||||
FF_DISABLE_DEPRECATION_WARNINGS
|
||||
void *destruct = avpkt->destruct;
|
||||
FF_ENABLE_DEPRECATION_WARNINGS
|
||||
#endif
|
||||
|
||||
if (avpkt->size < size) {
|
||||
@@ -1456,7 +1465,9 @@ int ff_alloc_packet2(AVCodecContext *avctx, AVPacket *avpkt, int size)
|
||||
|
||||
av_init_packet(avpkt);
|
||||
#if FF_API_DESTRUCT_PACKET
|
||||
FF_DISABLE_DEPRECATION_WARNINGS
|
||||
avpkt->destruct = destruct;
|
||||
FF_ENABLE_DEPRECATION_WARNINGS
|
||||
#endif
|
||||
avpkt->buf = buf;
|
||||
avpkt->size = size;
|
||||
@@ -2998,6 +3009,7 @@ int ff_match_2uint16(const uint16_t(*tab)[2], int size, int a, int b)
|
||||
}
|
||||
|
||||
#if FF_API_MISSING_SAMPLE
|
||||
FF_DISABLE_DEPRECATION_WARNINGS
|
||||
void av_log_missing_feature(void *avc, const char *feature, int want_sample)
|
||||
{
|
||||
av_log(avc, AV_LOG_WARNING, "%s is not implemented. Update your FFmpeg "
|
||||
@@ -3022,6 +3034,7 @@ void av_log_ask_for_sample(void *avc, const char *msg, ...)
|
||||
|
||||
va_end(argument_list);
|
||||
}
|
||||
FF_ENABLE_DEPRECATION_WARNINGS
|
||||
#endif /* FF_API_MISSING_SAMPLE */
|
||||
|
||||
static AVHWAccel *first_hwaccel = NULL;
|
||||
|
||||
Reference in New Issue
Block a user