From patchwork Thu Oct 26 14:23:27 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Niklas Haas X-Patchwork-Id: 44367 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:bf16:b0:15d:8365:d4b8 with SMTP id gc22csp671466pzb; Thu, 26 Oct 2023 07:24:42 -0700 (PDT) X-Google-Smtp-Source: AGHT+IE0Z7EKYzACUovMg0o3OOTPkNXe9XGd3rcrjtAAlyOQlzjlO4M8OiqEUhcmlDBu4DFu4X+v X-Received: by 2002:a17:906:7311:b0:9bd:9507:ed1c with SMTP id di17-20020a170906731100b009bd9507ed1cmr16150200ejc.18.1698330281701; Thu, 26 Oct 2023 07:24:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698330281; cv=none; d=google.com; s=arc-20160816; b=JMbDCVh9l4LywQvptJ1kPOQ2YG1PPjzEYLKzJwBABKTOWPOUbBxzA+xMjeTxhu+A6v t3DFzA8QXlTVNs7t9hABrqZCUTWjZ3BEt0AU4kNbkzfyEpkk+uhimc6pifZ1Z8YI4ftf o6s7JNaYOOFyySuvM+4thms72iALCmr/J4ZDJrJDWC2D9/aYvVGTxo3Ixt5caZdCgN/H vEFciPpO1e5nVXkqr83A4geTQzGLIwbnc/5n3FIiYUyGEPx9MVzXnPxrQGcias/An78c apTLfJ18If9uxEQs4fAf3e0nYcmoeEy51do5eUZJMJVBjGVeCQpBQWvrRkgdxZpX4CmW vyNQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:cc:reply-to :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:mime-version:references:in-reply-to :message-id:date:to:from:dkim-signature:delivered-to; bh=eVHBKM5QxJjLnh88eqoihJQ/LbldpqlYo6aaakpLvh4=; fh=xmAeKtysnShNOmkhiJmYkS30uw4Fu2hvBJ7qlIwukxQ=; b=E2K+9rIm86vxvIryG7VrmO8DnBbsGyoLxQgseh5gMPVzLQsLuld/CfFdEZnF6IrX7e sOv10OtudKJBdOalQ4B3yQDMeMEjll/Eo9mdF4BzC1jhr1mpcVNhzWxerNICx1s+gcBk eD0hm7X0PxxWQbI7YifE49FPRo5W1X+1RwuGqDAWsNNwr8e0t+EQ4U0pgaSio7AVPiOZ /NFVrCIwk35RId+C9kx/uZLVZQMEROd9R7Vrt1D8xK0R9obNXvrdXmXsYAP7gQzXzaJM aVRylXTbAAEjcPSWiDWG7kfjtMcWfhi20+M/keNjYkCcWejBo5pWRXbgdT97X3Vr8w1R mnTA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@haasn.xyz header.s=mail header.b="kQiHYbl/"; 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 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id f9-20020a17090624c900b009a633e2f3f8si6571585ejb.43.2023.10.26.07.24.20; Thu, 26 Oct 2023 07:24:41 -0700 (PDT) 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=@haasn.xyz header.s=mail header.b="kQiHYbl/"; 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 Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 1570F68CBB5; Thu, 26 Oct 2023 17:23:44 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from haasn.dev (haasn.dev [78.46.187.166]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 19B8468B4D7 for ; Thu, 26 Oct 2023 17:23:34 +0300 (EEST) Received: from haasn.dev (unknown [10.30.0.2]) by haasn.dev (Postfix) with ESMTP id D20944BBCC; Thu, 26 Oct 2023 16:23:33 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=haasn.xyz; s=mail; t=1698330213; bh=TOVXDmTKPdL69mYDoGYcbG+s+pajMbFqjczNcVAEWQU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=kQiHYbl/0K6A8YWSXz9VQk8k6IwxlOlnQiwE9G0r9FFyzjouF0LvC4dWK16eHVx7S 414K5g8zWFCfdrgz+EpomQit5UP/lpyUzUaahKlMT9IsJt203ltjFcrag91MdZiybO TM5Diitgb2C4Qcxr6QPVrvLxkDjWpZQfqOEesC/Y= From: Niklas Haas To: ffmpeg-devel@ffmpeg.org Date: Thu, 26 Oct 2023 16:23:27 +0200 Message-ID: <20231026142327.52694-5-ffmpeg@haasn.xyz> X-Mailer: git-send-email 2.42.0 In-Reply-To: <20231026142327.52694-1-ffmpeg@haasn.xyz> References: <20231026142327.52694-1-ffmpeg@haasn.xyz> MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH v2 5/5] avformat/vf_vapoursynth: simplify xyz format check 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: Niklas Haas Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: abcF+PIT4AqB From: Niklas Haas --- libavformat/vapoursynth.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/libavformat/vapoursynth.c b/libavformat/vapoursynth.c index 965d36dc2e..b79ecfcf1b 100644 --- a/libavformat/vapoursynth.c +++ b/libavformat/vapoursynth.c @@ -118,7 +118,8 @@ static av_cold enum AVPixelFormat match_pixfmt(const VSFormat *vsf, int c_order[ pixfmt = av_pix_fmt_desc_get_id(pd); if (pd->flags & (AV_PIX_FMT_FLAG_BAYER | AV_PIX_FMT_FLAG_ALPHA | - AV_PIX_FMT_FLAG_HWACCEL | AV_PIX_FMT_FLAG_BITSTREAM)) + AV_PIX_FMT_FLAG_HWACCEL | AV_PIX_FMT_FLAG_BITSTREAM | + AV_PIX_FMT_FLAG_XYZ)) continue; if (pd->log2_chroma_w != vsf->subSamplingW || @@ -141,9 +142,6 @@ static av_cold enum AVPixelFormat match_pixfmt(const VSFormat *vsf, int c_order[ if (av_pix_fmt_count_planes(pixfmt) != vsf->numPlanes) continue; - if (strncmp(pd->name, "xyz", 3) == 0) - continue; - if (!is_native_endian(pixfmt)) continue;