Merge commit 'b3739599bda740ac12d3dde31a331b744df99123'
* commit 'b3739599bda740ac12d3dde31a331b744df99123': lavc: Drop deprecated emu edge functionality Merged-by: James Almer <jamrial@gmail.com>
This commit is contained in:
commit
7b550c5f84
@ -796,9 +796,6 @@ static void add_input_streams(OptionsContext *o, AVFormatContext *ic)
|
||||
ist->dec_ctx->height = st->codec->height;
|
||||
ist->dec_ctx->coded_width = st->codec->coded_width;
|
||||
ist->dec_ctx->coded_height = st->codec->coded_height;
|
||||
#if FF_API_EMU_EDGE
|
||||
ist->dec_ctx->flags |= CODEC_FLAG_EMU_EDGE;
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
|
||||
|
@ -2604,15 +2604,8 @@ static int stream_component_open(VideoState *is, int stream_index)
|
||||
}
|
||||
av_codec_set_lowres(avctx, stream_lowres);
|
||||
|
||||
#if FF_API_EMU_EDGE
|
||||
if(stream_lowres) avctx->flags |= CODEC_FLAG_EMU_EDGE;
|
||||
#endif
|
||||
if (fast)
|
||||
avctx->flags2 |= AV_CODEC_FLAG2_FAST;
|
||||
#if FF_API_EMU_EDGE
|
||||
if(codec->capabilities & AV_CODEC_CAP_DR1)
|
||||
avctx->flags |= CODEC_FLAG_EMU_EDGE;
|
||||
#endif
|
||||
|
||||
opts = filter_codec_opts(codec_opts, avctx->codec_id, ic, ic->streams[stream_index], codec);
|
||||
if (!av_dict_get(opts, "threads", NULL, 0))
|
||||
|
@ -1109,13 +1109,6 @@ typedef struct RcOverride{
|
||||
#define CODEC_FLAG_PASS1 AV_CODEC_FLAG_PASS1
|
||||
#define CODEC_FLAG_PASS2 AV_CODEC_FLAG_PASS2
|
||||
#define CODEC_FLAG_GRAY AV_CODEC_FLAG_GRAY
|
||||
#if FF_API_EMU_EDGE
|
||||
/**
|
||||
* @deprecated edges are not used/required anymore. I.e. this flag is now always
|
||||
* set.
|
||||
*/
|
||||
#define CODEC_FLAG_EMU_EDGE 0x4000
|
||||
#endif
|
||||
#define CODEC_FLAG_PSNR AV_CODEC_FLAG_PSNR
|
||||
#define CODEC_FLAG_TRUNCATED AV_CODEC_FLAG_TRUNCATED
|
||||
|
||||
@ -4713,21 +4706,6 @@ AVCodec *avcodec_find_decoder_by_name(const char *name);
|
||||
*/
|
||||
int avcodec_default_get_buffer2(AVCodecContext *s, AVFrame *frame, int flags);
|
||||
|
||||
#if FF_API_EMU_EDGE
|
||||
/**
|
||||
* Return the amount of padding in pixels which the get_buffer callback must
|
||||
* provide around the edge of the image for codecs which do not have the
|
||||
* CODEC_FLAG_EMU_EDGE flag.
|
||||
*
|
||||
* @return Required padding in pixels.
|
||||
*
|
||||
* @deprecated CODEC_FLAG_EMU_EDGE is deprecated, so this function is no longer
|
||||
* needed
|
||||
*/
|
||||
attribute_deprecated
|
||||
unsigned avcodec_get_edge_width(void);
|
||||
#endif
|
||||
|
||||
/**
|
||||
* Modify width and height values so that they will result in a memory
|
||||
* buffer that is acceptable for the codec if you do not use any horizontal
|
||||
|
@ -358,12 +358,6 @@ static int amv_encode_picture(AVCodecContext *avctx, AVPacket *pkt,
|
||||
|
||||
av_pix_fmt_get_chroma_sub_sample(avctx->pix_fmt, &chroma_h_shift, &chroma_v_shift);
|
||||
|
||||
#if FF_API_EMU_EDGE
|
||||
//CODEC_FLAG_EMU_EDGE have to be cleared
|
||||
if(s->avctx->flags & CODEC_FLAG_EMU_EDGE)
|
||||
return AVERROR(EINVAL);
|
||||
#endif
|
||||
|
||||
if ((avctx->height & 15) && avctx->strict_std_compliance > FF_COMPLIANCE_UNOFFICIAL) {
|
||||
av_log(avctx, AV_LOG_ERROR,
|
||||
"Heights which are not a multiple of 16 might fail with some decoders, "
|
||||
|
@ -66,9 +66,6 @@ static const AVOption avcodec_options[] = {
|
||||
{"pass1", "use internal 2-pass ratecontrol in first pass mode", 0, AV_OPT_TYPE_CONST, {.i64 = AV_CODEC_FLAG_PASS1 }, INT_MIN, INT_MAX, 0, "flags"},
|
||||
{"pass2", "use internal 2-pass ratecontrol in second pass mode", 0, AV_OPT_TYPE_CONST, {.i64 = AV_CODEC_FLAG_PASS2 }, INT_MIN, INT_MAX, 0, "flags"},
|
||||
{"gray", "only decode/encode grayscale", 0, AV_OPT_TYPE_CONST, {.i64 = AV_CODEC_FLAG_GRAY }, INT_MIN, INT_MAX, V|E|D, "flags"},
|
||||
#if FF_API_EMU_EDGE
|
||||
{"emu_edge", "do not draw edges", 0, AV_OPT_TYPE_CONST, {.i64 = CODEC_FLAG_EMU_EDGE }, INT_MIN, INT_MAX, 0, "flags"},
|
||||
#endif
|
||||
{"psnr", "error[?] variables will be set during encoding", 0, AV_OPT_TYPE_CONST, {.i64 = AV_CODEC_FLAG_PSNR }, INT_MIN, INT_MAX, V|E, "flags"},
|
||||
{"truncated", "Input bitstream might be randomly truncated", 0, AV_OPT_TYPE_CONST, {.i64 = AV_CODEC_FLAG_TRUNCATED }, INT_MIN, INT_MAX, V|D, "flags"},
|
||||
#if FF_API_NORMALIZE_AQP
|
||||
|
@ -1622,11 +1622,7 @@ static int encode_frame(AVCodecContext *avctx, AVPacket *pkt,
|
||||
s->lambda = 0;
|
||||
}//else keep previous frame's qlog until after motion estimation
|
||||
|
||||
if (s->current_picture->data[0]
|
||||
#if FF_API_EMU_EDGE
|
||||
&& !(s->avctx->flags&CODEC_FLAG_EMU_EDGE)
|
||||
#endif
|
||||
) {
|
||||
if (s->current_picture->data[0]) {
|
||||
int w = s->avctx->width;
|
||||
int h = s->avctx->height;
|
||||
|
||||
|
@ -191,13 +191,6 @@ av_cold void avcodec_register(AVCodec *codec)
|
||||
codec->init_static_data(codec);
|
||||
}
|
||||
|
||||
#if FF_API_EMU_EDGE
|
||||
unsigned avcodec_get_edge_width(void)
|
||||
{
|
||||
return EDGE_WIDTH;
|
||||
}
|
||||
#endif
|
||||
|
||||
int ff_set_dimensions(AVCodecContext *s, int width, int height)
|
||||
{
|
||||
int ret = av_image_check_size2(width, height, s->max_pixels, AV_PIX_FMT_NONE, 0, s);
|
||||
|
@ -57,9 +57,6 @@
|
||||
#ifndef FF_API_DEBUG_MV
|
||||
#define FF_API_DEBUG_MV (LIBAVCODEC_VERSION_MAJOR < 58)
|
||||
#endif
|
||||
#ifndef FF_API_EMU_EDGE
|
||||
#define FF_API_EMU_EDGE (LIBAVCODEC_VERSION_MAJOR < 58)
|
||||
#endif
|
||||
#ifndef FF_API_UNUSED_MEMBERS
|
||||
#define FF_API_UNUSED_MEMBERS (LIBAVCODEC_VERSION_MAJOR < 58)
|
||||
#endif
|
||||
|
@ -460,10 +460,6 @@ static av_cold int wmv2_decode_init(AVCodecContext *avctx)
|
||||
Wmv2Context *const w = avctx->priv_data;
|
||||
int ret;
|
||||
|
||||
#if FF_API_EMU_EDGE
|
||||
avctx->flags |= CODEC_FLAG_EMU_EDGE;
|
||||
#endif
|
||||
|
||||
if ((ret = ff_msmpeg4_decode_init(avctx)) < 0)
|
||||
return ret;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user