This is an automated email from the git hooks/post-receive script. Git pushed a commit to branch master in repository ffmpeg.
commit dc705268c72a07f796f803837f1c56a3ec46a9a7 Author: Niklas Haas <[email protected]> AuthorDate: Sun Mar 29 12:57:51 2026 +0200 Commit: Niklas Haas <[email protected]> CommitDate: Thu Apr 2 11:48:15 2026 +0000 swscale/ops: define flags_identity as an enum constant Signed-off-by: Niklas Haas <[email protected]> --- libswscale/ops.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/libswscale/ops.c b/libswscale/ops.c index 1e6d68b210..e77906b94a 100644 --- a/libswscale/ops.c +++ b/libswscale/ops.c @@ -250,12 +250,15 @@ void ff_sws_apply_op_q(const SwsOp *op, AVRational x[4]) av_unreachable("Invalid operation type!"); } -/* merge_comp_flags() forms a monoid with flags_identity as the null element */ -static const SwsCompFlags flags_identity = SWS_COMP_ZERO | SWS_COMP_EXACT; +/* merge_comp_flags() forms a monoid with SWS_COMP_IDENTITY as the null element */ +enum { + SWS_COMP_IDENTITY = SWS_COMP_ZERO | SWS_COMP_EXACT, +}; + static SwsCompFlags merge_comp_flags(SwsCompFlags a, SwsCompFlags b) { const SwsCompFlags flags_or = SWS_COMP_GARBAGE; - const SwsCompFlags flags_and = SWS_COMP_ZERO | SWS_COMP_EXACT; + const SwsCompFlags flags_and = SWS_COMP_IDENTITY; return ((a & b) & flags_and) | ((a | b) & flags_or); } @@ -390,7 +393,7 @@ void ff_sws_op_list_update_comps(SwsOpList *ops) } break; case SWS_OP_PACK: { - SwsCompFlags flags = flags_identity; + SwsCompFlags flags = SWS_COMP_IDENTITY; for (int i = 0; i < 4; i++) { if (op->pack.pattern[i]) flags = merge_comp_flags(flags, prev.flags[i]); @@ -426,7 +429,7 @@ void ff_sws_op_list_update_comps(SwsOpList *ops) break; case SWS_OP_LINEAR: for (int i = 0; i < 4; i++) { - SwsCompFlags flags = flags_identity; + SwsCompFlags flags = SWS_COMP_IDENTITY; AVRational min = Q(0), max = Q(0); for (int j = 0; j < 4; j++) { const AVRational k = op->lin.m[i][j]; _______________________________________________ ffmpeg-cvslog mailing list -- [email protected] To unsubscribe send an email to [email protected]
