diff options
author | James Almer <jamrial@gmail.com> | 2023-05-17 22:39:57 -0300 |
---|---|---|
committer | James Almer <jamrial@gmail.com> | 2023-05-18 08:45:23 -0300 |
commit | 63767b79a570404628b2521b83104108b7b6884c (patch) | |
tree | ba05301188d4deb51854721e0e60bfca4edb0323 /libavcodec/ansi.c | |
parent | 01d9a84ef58c2d0d89958b18420483b058ac9dd1 (diff) |
avutil/frame: deprecate palette_has_changed
Not only this is information that relies on the concept of a sequence of
frames, which is completely out of place as a field in AVFrame, but there are
no known or intended uses of this field.
Signed-off-by: James Almer <jamrial@gmail.com>
Diffstat (limited to 'libavcodec/ansi.c')
-rw-r--r-- | libavcodec/ansi.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/libavcodec/ansi.c b/libavcodec/ansi.c index c1e31266ec..49c3770c4c 100644 --- a/libavcodec/ansi.c +++ b/libavcodec/ansi.c @@ -262,7 +262,11 @@ static int execute_code(AVCodecContext * avctx, int c) AV_GET_BUFFER_FLAG_REF)) < 0) return ret; s->frame->pict_type = AV_PICTURE_TYPE_I; +#if FF_API_PALETTE_HAS_CHANGED +FF_DISABLE_DEPRECATION_WARNINGS s->frame->palette_has_changed = 1; +FF_ENABLE_DEPRECATION_WARNINGS +#endif set_palette((uint32_t *)s->frame->data[1]); erase_screen(avctx); } else if (c == 'l') { @@ -371,7 +375,11 @@ static int decode_frame(AVCodecContext *avctx, AVFrame *rframe, } s->frame->pict_type = AV_PICTURE_TYPE_I; +#if FF_API_PALETTE_HAS_CHANGED +FF_DISABLE_DEPRECATION_WARNINGS s->frame->palette_has_changed = 1; +FF_ENABLE_DEPRECATION_WARNINGS +#endif set_palette((uint32_t *)s->frame->data[1]); if (!s->first_frame) { erase_screen(avctx); |