aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoraverne <averne381@gmail.com>2025-07-31 19:39:31 +0200
committerLynne <dev@lynne.ee>2025-08-02 06:11:39 +0000
commitbf79148cbb8719314e5ea53c9597f8cd35f9c0b5 (patch)
tree4a77c364b8a4f3bbf3f98d800e8dc94141307034
parenta49108fd2923f9444af04727457d14300e96666f (diff)
downloadffmpeg-bf79148cbb8719314e5ea53c9597f8cd35f9c0b5.tar.gz
avcodec/proresenc_anatoliy: Remove support for grayscale flag
This results in the encoder producing empty scans for chroma planes, which is illegal according to the ProRes SMPTE document.
-rw-r--r--libavcodec/proresenc_anatoliy.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/libavcodec/proresenc_anatoliy.c b/libavcodec/proresenc_anatoliy.c
index 4fc40abaac..1d40410199 100644
--- a/libavcodec/proresenc_anatoliy.c
+++ b/libavcodec/proresenc_anatoliy.c
@@ -397,14 +397,12 @@ static av_always_inline unsigned encode_slice_data(AVCodecContext *avctx,
*y_data_size = encode_slice_plane(blocks_y, mb_count,
buf, data_size, ctx->qmat_luma[qp - 1], 0, ctx->scantable);
- if (!(avctx->flags & AV_CODEC_FLAG_GRAY)) {
- *u_data_size = encode_slice_plane(blocks_u, mb_count, buf + *y_data_size, data_size - *y_data_size,
- ctx->qmat_chroma[qp - 1], ctx->is_422, ctx->scantable);
+ *u_data_size = encode_slice_plane(blocks_u, mb_count, buf + *y_data_size, data_size - *y_data_size,
+ ctx->qmat_chroma[qp - 1], ctx->is_422, ctx->scantable);
- *v_data_size = encode_slice_plane(blocks_v, mb_count, buf + *y_data_size + *u_data_size,
- data_size - *y_data_size - *u_data_size,
- ctx->qmat_chroma[qp - 1], ctx->is_422, ctx->scantable);
- }
+ *v_data_size = encode_slice_plane(blocks_v, mb_count, buf + *y_data_size + *u_data_size,
+ data_size - *y_data_size - *u_data_size,
+ ctx->qmat_chroma[qp - 1], ctx->is_422, ctx->scantable);
return *y_data_size + *u_data_size + *v_data_size;
}