This is an automated email from the git hooks/post-receive script. Git pushed a commit to branch master in repository ffmpeg.
commit d26994d35f9dd4f8080bde57805f112362c061fe Author: Niklas Haas <[email protected]> AuthorDate: Tue Jun 9 13:06:04 2026 +0200 Commit: Niklas Haas <[email protected]> CommitDate: Sat Jun 20 14:08:49 2026 +0000 swscale/format: exclude palette formats for output In theory, we could learn to handle them internally, using the same systematic palette trick, but I'll defer this for now, as vf_scale already handles this internally. Sponsored-by: Sovereign Tech Fund Signed-off-by: Niklas Haas <[email protected]> --- libswscale/format.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/libswscale/format.c b/libswscale/format.c index 0538ab9db4..48eee12696 100644 --- a/libswscale/format.c +++ b/libswscale/format.c @@ -937,7 +937,11 @@ static int test_format_ops(enum AVPixelFormat format, int output) SwsPixelType pixel_type, raw_type; int ret = fmt_analyze(format, &rw, &pack, &swizzle, &shift, &pixel_type, &raw_type); - return ret == 0; + if (ret < 0) + return 0; + if (rw.mode == SWS_RW_PALETTE && output) + return 0; /* palettes are currently only supported as input */ + return 1; } static void swizzle_inv(SwsSwizzleOp *swiz) @@ -1085,6 +1089,9 @@ int ff_sws_encode_pixfmt(SwsOpList *ops, const SwsFormat *fmt) RET(fmt_analyze(fmt->format, &rw_op, &pack, &swizzle, &shift, &pixel_type, &raw_type)); + if (rw_op.mode == SWS_RW_PALETTE) + return AVERROR(ENOTSUP); + if (shift.amount) { RET(ff_sws_op_list_append(ops, &(SwsOp) { .op = SWS_OP_LSHIFT, _______________________________________________ ffmpeg-cvslog mailing list -- [email protected] To unsubscribe send an email to [email protected]
