From patchwork Sat Nov 27 14:03:06 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 31760 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a6b:d206:0:0:0:0:0 with SMTP id q6csp3677932iob; Sat, 27 Nov 2021 06:03:29 -0800 (PST) X-Google-Smtp-Source: ABdhPJwhRpSrWzDmwRdtWXYVQgn9vSyNfjPEcwQJdYEFFS036/llrgBNfg1MyznwZTOFKwB5Xogt X-Received: by 2002:a17:906:ecac:: with SMTP id qh12mr45363510ejb.377.1638021809033; Sat, 27 Nov 2021 06:03:29 -0800 (PST) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id sa38si20157325ejc.540.2021.11.27.06.03.28; Sat, 27 Nov 2021 06:03:29 -0800 (PST) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=Ol15sWxr; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 1D9BB68A0E7; Sat, 27 Nov 2021 16:03:25 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR05-DB8-obe.outbound.protection.outlook.com (mail-db8eur05olkn2086.outbound.protection.outlook.com [40.92.89.86]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id F070E68A7DE for ; Sat, 27 Nov 2021 16:03:17 +0200 (EET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=WGWRLpumBu4yvEPLX0zg7aJ+YPEk80YS0Aamb5YR3EEFV9WaF65kCxg6NYbDD4DfZus7xEdqA1XNgGxMMCUucKAVm0hx0XTRBaEXdbmhNC34yZhnm1neL+mZRF7hs51ulZp34nyX0ryuSzvGETh5HOd/GZ5B7Ob2ZqAFPsXCL/+phi8waCe9JHcF/RKLfYd1krjrri42qmAZdqhvoh8lGDzoSoMqo7ypZk05WHwyxVvbW0KUTRSjw7aUVE0roqLQ2QunP6VvC91Tz0NiXeVpV0mFX0nA263mOzoklWz1szND77k5RLNaIUyLyUqN9rfJZz+QhGzSl6iGlTD1CMTTyw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=SGRMp7Jvdxc4TusYsXHQa6CogoCVkroOhblESlsgrmk=; b=noyHF+jwSjPAl1GiQlrp6NDetQzJnnLcyuMb6xF+pySyxA4IcunLIwm/YknwfQ/47wb+agVuoowFF4NJGvd82b6h6p13Ba+HWqmleoIPMNRqzj0HXt5wbWxc9gVMHI0zUSNrQ0BUq4aZ1ByN+mbVHU5aaHnX4P59oHibrf8q7FYnRkectc0j089m4gsRf+3dP4yEzSmgmpydd2MFp8CKbUyLGDStqMPk8Fsl2O6ioUbsvAVADpqBkJptcrXV1hmIuuaSy9YAydJPhGpDy8CRbCZ7/b0/3IqYBuh83VqS7O7leiBg5+gHYnAPolnzSzQsO+bqsD4Oa1VYMQ/5UPJMgQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=SGRMp7Jvdxc4TusYsXHQa6CogoCVkroOhblESlsgrmk=; b=Ol15sWxrHtGHRu2DE260mMK4jOaEzF6QVpvl3fGM89GL8k7bRjf0VVnf3xonvCDwec9z60EgfBtSieEmI1TF3bE9iNm2gFHzX426GsPjbkIAgOA3FrGwNysCWcw+yOo3LyjAEt00fTGZRWjhXynmPpVIlke0vE2Ug9fwybgHPzL0CRMONQXeg9LUtR6MONtT5CUQ/oOQc2RT5Qycqy7BWyaWqJN4vREnAyafeZQPVTe6jzy+W+2956A983Ov7IypYSOAAo09YSg3xikTIXEvicJy5HHpXJ8jdyL0EMDZ2hzj7Rn5z1iSZs/aPu8tilRuE6oqXLDHDotlzx7TrYlx4Q== Received: from AM7PR03MB6660.eurprd03.prod.outlook.com (2603:10a6:20b:1c1::22) by AS8PR03MB6919.eurprd03.prod.outlook.com (2603:10a6:20b:29c::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4734.21; Sat, 27 Nov 2021 14:03:16 +0000 Received: from AM7PR03MB6660.eurprd03.prod.outlook.com ([fe80::700f:d70b:3bb8:4d51]) by AM7PR03MB6660.eurprd03.prod.outlook.com ([fe80::700f:d70b:3bb8:4d51%9]) with mapi id 15.20.4734.023; Sat, 27 Nov 2021 14:03:16 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Sat, 27 Nov 2021 15:03:06 +0100 Message-ID: X-Mailer: git-send-email 2.32.0 X-TMN: [Cn4nkJylbnwoB+u8bgyLOWGYMuxUutQt] X-ClientProxiedBy: AS9PR06CA0375.eurprd06.prod.outlook.com (2603:10a6:20b:460::19) To AM7PR03MB6660.eurprd03.prod.outlook.com (2603:10a6:20b:1c1::22) X-Microsoft-Original-Message-ID: <20211127140306.293370-1-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from sblaptop.fritz.box (188.192.248.74) by AS9PR06CA0375.eurprd06.prod.outlook.com (2603:10a6:20b:460::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4734.21 via Frontend Transport; Sat, 27 Nov 2021 14:03:15 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 936a162a-a3ee-472b-644f-08d9b1aea881 X-MS-Exchange-SLBlob-MailProps: LtmIgUwM0qTpsfhc92M9shNIJKE6ERKW3U8dG83CPgZV2fs6kBZsJi0A83+dYs35kQJJvxON/FrRcGIW2Ya7TwcmzNV5CmHCyMVH9Zn/X6FBVPE1P//s+Y6g5oaI36beSmj0TBmGQ11lR6iOLFPnKvhVwuHXlz3dsq7Z9PAT46+3zOny3b1yzufal6SRV4QcNO+BhgaxAH21feir+2q+nznVIQHVqvKGjmJHk/XH5APO60Df/I6gj4STmaS1QDtnTtLgUtuceVF2OdhlisrmS5ubB+fyBkz3BYWXjpUYcY2bRLJ5CZHafhE3wv3ELjFAXBOs/9tsrFugagA9jx9DJPFp7VIbI2s7HbZukzg+mZMgGlimqzVmMQpgbEkgzMJRgKi4txUj/AajOQcTzm7Hjw0ieYHqmBjWnu3H4rb3B5CftuEikmoZ9VlK+4OdoRR0hvx/8Enq7VIgiwOEPJT8izatXVWKe6mvqVDD2swSoWcQHTptmZsdDpGHAtKpL81q64y0BDC4sDsFbzTU0NfNXUGq63xDrzhfx/CiRjepgoCTdhVRxRmTvA5tz8tYce/dxhAXNM0VVsI5W1cZxe/Cjx10Er4XnYr6OkGeHMeTgdQn19J2z7g7mrVWrG9t5fuUvvfodrtNw18ft10A+8tb+npUhucEWoSs5j4grmfzO499W1Kyeuc2++ke2E+VzizWySrmFT8zQfZzY+0DbpeAm6bwtmKXym31WrlYi7lHgQkcPc6OJQrpbRJPfLwaOWse1eURV6K2JBGK+mj6LVOH/Q== X-MS-TrafficTypeDiagnostic: AS8PR03MB6919: X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: +jVKn7usvxpmwQnYMpzQY1QtlpG+e70bnFS7sIGgyoFOZQ8VJtp3KsC9YHDF/45y9Jf7EykBQHQd0QvqOQ60sRGK20jbiI5v/Ko7T6fgstjP2NvlfX8Elg5/LE6GVyG3IafwOj3mnTM2r+blCjWSabeHClRqYMS0EQfl6aVGVYN3/aSPFfrwQUGQXrqUM9Vdbt6nxHPMPVaXt9zZupN+gtYWHEvzhaZUGY3i2oSS5sjoRq74uZpGyoDEkGRfNqTtJXChh8RRnnculs6c8AtgWiT8xG/C1SnlxQti2mp8CGjxkcP/jrnK2N9Br6ecYFP1HxWgUJgojnRdrSbpqLgtuSNQ+ne8d+ZuaKtE805pA1uS+NE4lCRawHWVHblbRB1XOkgzc7/nwWpStkpZv6M8DoQWLBP/R/lSenGoeZpoBFT7oSVZ1wMNWcu2M41k5XxcFw0EshGuuT8FZ4Ny2l776v0hFzSllqGUkabd4pHNl03TP5oNcSzptx12d8tthj39+AxQXgjHtdxCY/SLqPTxzHrU5OqgUqX+KG0tXQEqmgxEWxag4VuOhEsujzyTo3cHYv8bf8h/Vui7JwQq7uqkvQ== X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: Usvq1/Ndo5T54tMOSzDUo/a5LAKNdeW/uJPRw+QQV5eLMI0cY5gqngi/gjmvX68qqnYaSmnYs6H6nicpPVFezNczrKMAhR9v/1guX6TRSUjRnL66+wuWYCRfNzvz/PmzezOi2SFLyXEClCwVHgMs69zn+b2qRtfbBy0EqRBDfy0uRDBRXYbQXcCO20pb/zyhw+36OtNwzUjDi3WHj7k1kjOI3X9DWdNyrj8awqvrJ/GefisCORxvFl3QVzja2dkoNtNEtAsOtL6ytB+6hcbnQ1JO4M8K3pXUUrKyZ4xJDWO8kkMy6oEqqKOlqeZoXMbFD3gS2iMmBnuGZGMxfsWEx6AQP4C/G5V93Kq6KCvpPGYvlbLD70UDsWeYIFi7Phvf2iGuCqxAlpT6rmnZOJfxS13G+mOjjiqNmRzdFWF6rLEje5AELQiD3wURWhji4apVOO3rASjGXuoDQVWNiBo5pawGDe5NgkvPR9e5flZS6L8rQppIRxMm1jrU2vzERwKCHbQuFtqK33dOBqMKHVHd0LQhU0mOXBWFT2vlUt75rKanZWz8ihVM9gU2SNcZJJBQ9KD1Y+6UBa4PFkCGIPQi98tVp3X4yCUXECGv0n69L/cftnHlNyELyJ4f99m4jh9a2sISotgO6iK2zYV8k9NnJEif9lWMresaDrNQDGbA5B4IV4CZP8X90Yx65JAO/i9CqqC3G61r0SHumRZHViiXU83+PbvZXtYXrULfI9shtZMV6COb66/gxH6RKFfM+y/qJ8CMi2wh1QVYCxnEsn2pnlJykZqWPV8RdgvpV5ghjeOu0jPCk0ND9z0EnDC5s2I6feDxMmOC6rsCsp23wXMLk50rXi+N7QTp8criRRVGwgQ87/lBvHl6u1aSVdpo2Bb77DoezszvoHvFP/ZnI25JqX/uh2UfMWqhH3Tgm/2WZpk5Eqd9yXnv9/yl6sb7grftL2oeAjeiX+LKglEE2giFvg== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 936a162a-a3ee-472b-644f-08d9b1aea881 X-MS-Exchange-CrossTenant-AuthSource: AM7PR03MB6660.eurprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 27 Nov 2021 14:03:16.2060 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8PR03MB6919 Subject: [FFmpeg-devel] [PATCH] avfilter/vf_paletteuse: Add missing parentheses X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Soft Works , Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: zJKFdV1qvGmB Fixes a mistake in dea673d0d548c864ec85f9260d8900d944ef7a2a. GCC emitted a -Wint-in-bool-context warning because of that. Reviewed-by: Soft Works Signed-off-by: Andreas Rheinhardt --- Will apply this tonight unless there are objections. libavfilter/vf_paletteuse.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavfilter/vf_paletteuse.c b/libavfilter/vf_paletteuse.c index 5f20cd75b2..5b300be5a5 100644 --- a/libavfilter/vf_paletteuse.c +++ b/libavfilter/vf_paletteuse.c @@ -811,7 +811,7 @@ static void debug_mean_error(PaletteUseContext *s, const AVFrame *in1, uint8_t *src2 = in2->data[0]; const int src1_linesize = in1->linesize[0] >> 2; const int src2_linesize = in2->linesize[0]; - const float div = in1->width * in1->height * s->use_alpha ? 4 : 3; + const float div = in1->width * in1->height * (s->use_alpha ? 4 : 3); unsigned mean_err = 0; for (y = 0; y < in1->height; y++) {