This is an automated email from the git hooks/post-receive script. Git pushed a commit to branch master in repository ffmpeg.
commit c00b5be5de33a7074cade850c8e51beba3393143 Author: Ramiro Polla <[email protected]> AuthorDate: Thu Jun 18 20:36:19 2026 +0200 Commit: Ramiro Polla <[email protected]> CommitDate: Fri Jun 19 14:32:44 2026 +0000 swscale/format: modify SwsSwizzleOp in-place in swizzle_inv() --- libswscale/format.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/libswscale/format.c b/libswscale/format.c index 3f8e10d07b..545ba1909e 100644 --- a/libswscale/format.c +++ b/libswscale/format.c @@ -939,14 +939,15 @@ static int test_format_ops(enum AVPixelFormat format, int output) return ret == 0; } -static SwsSwizzleOp swizzle_inv(SwsSwizzleOp swiz) { +static void swizzle_inv(SwsSwizzleOp *swiz) +{ /* Input[x] =: Output[swizzle.x] */ - unsigned out[4]; - out[swiz.x] = 0; - out[swiz.y] = 1; - out[swiz.z] = 2; - out[swiz.w] = 3; - return (SwsSwizzleOp) {{ .x = out[0], out[1], out[2], out[3] }}; + unsigned tmp[4]; + tmp[swiz->x] = 0; + tmp[swiz->y] = 1; + tmp[swiz->z] = 2; + tmp[swiz->w] = 3; + *swiz = (SwsSwizzleOp) {{ .x = tmp[0], tmp[1], tmp[2], tmp[3] }}; } /** @@ -996,7 +997,7 @@ int ff_sws_decode_pixfmt(SwsOpList *ops, enum AVPixelFormat fmt) RET(fmt_analyze(fmt, &rw_op, &unpack, &swizzle, &shift, &pixel_type, &raw_type)); - swizzle = swizzle_inv(swizzle); + swizzle_inv(&swizzle); /* Set baseline pixel content flags */ const int integer = ff_sws_pixel_type_is_int(raw_type); _______________________________________________ ffmpeg-cvslog mailing list -- [email protected] To unsubscribe send an email to [email protected]
