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>
This commit is contained in:
James Almer
2023-05-17 22:39:57 -03:00
parent 01d9a84ef5
commit 63767b79a5
48 changed files with 267 additions and 15 deletions

View File

@@ -651,7 +651,11 @@ static int dds_decode(AVCodecContext *avctx, AVFrame *frame,
((unsigned)frame->data[1][3+i*4]<<24)
);
}
#if FF_API_PALETTE_HAS_CHANGED
FF_DISABLE_DEPRECATION_WARNINGS
frame->palette_has_changed = 1;
FF_ENABLE_DEPRECATION_WARNINGS
#endif
if (bytestream2_get_bytes_left(gbc) < frame->height * frame->width / 2) {
av_log(avctx, AV_LOG_ERROR, "Buffer is too small (%d < %d).\n",
@@ -682,7 +686,11 @@ static int dds_decode(AVCodecContext *avctx, AVFrame *frame,
((unsigned)frame->data[1][3+i*4]<<24)
);
#if FF_API_PALETTE_HAS_CHANGED
FF_DISABLE_DEPRECATION_WARNINGS
frame->palette_has_changed = 1;
FF_ENABLE_DEPRECATION_WARNINGS
#endif
}
if (bytestream2_get_bytes_left(gbc) < frame->height * linesize) {