From patchwork Fri Nov 19 13:52:42 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wu Jianhua X-Patchwork-Id: 31489 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a6b:d206:0:0:0:0:0 with SMTP id q6csp2413676iob; Fri, 19 Nov 2021 05:53:48 -0800 (PST) X-Google-Smtp-Source: ABdhPJwIaEx/J4kS2JHlYeOZ+NeoHAWzLVWbPjLooVK8M3+D8HzypI0byxijqM5SEgzNNtv3Zx3L X-Received: by 2002:a17:907:ea0:: with SMTP id ho32mr7881168ejc.191.1637330028356; Fri, 19 Nov 2021 05:53:48 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1637330028; cv=none; d=google.com; s=arc-20160816; b=MwmWoSSCENLs6rqhciAKTQD+R8RSuNKx82aY2XgeRup4xTuXUOOTC4xB2wZ1nkka0l ncLhBXnVZOAatVfB+t/69OfhlplVAa/iUpUe7BLQtCj9NG1lmrYNM1sCIqueVAOkk+lN G3YptB+S9P1t8g3W3z8xxUCKHC1aEt8/iUF0Fv6YlymGUL7MZeyuGrUbRW8uYSoWLtZy V/ZsztqwJY9PRfvItw0xm02AUQjv/cuGGn3Er6/05pysh1EjRRugLJlFYUczxFGy/W5e jOo4Xqjcfnjs16O6i9RH0Fx8XmHGySvCs5RB9nOB8dDSrmCRYKm6bwSNIKAnQJqg8c+A LekA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version:cc:reply-to :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:references:in-reply-to:message-id:date :to:from:delivered-to; bh=+Dx3EMERXonIfWKbXaucXnk42yQIbFYMFKVMx0hxFqU=; b=aIEBo+IKn/qrzigFFXZqUz41w/TY3iMapJwh4zPCxevULnhQh/OLNqry1e/E/k8PB0 Zlm8YCBjbUmO++bAd8rQAcg5lQseI0QPsQFLWz98wPoY/Tow/IfSp6essTD4efij/pCM AqUuhDtwcD3Hf+umiDINtYKKukkrvQ2IhFuVnYhbrbbRW17y/TMT0/jJveSN34ChBtsd aAip7TYBK8/lVcnwU9RXUzgXl5ZztiWci7XwKeklotTsCIo0KoqxuEd44sEkXbKG7I/b heM1n+8UilwiV9nvJosycGxaJ838enfHlBrWIjG6FcsmNuEJtk7mYJTKbQKX40ic2wn4 PpyQ== ARC-Authentication-Results: i=1; mx.google.com; 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=NONE dis=NONE) header.from=intel.com Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id ho42si8878501ejc.50.2021.11.19.05.53.47; Fri, 19 Nov 2021 05:53:48 -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; 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=NONE dis=NONE) header.from=intel.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 04A1268A973; Fri, 19 Nov 2021 15:53:11 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id D76B868A764 for ; Fri, 19 Nov 2021 15:53:03 +0200 (EET) X-IronPort-AV: E=McAfee;i="6200,9189,10172"; a="231896458" X-IronPort-AV: E=Sophos;i="5.87,247,1631602800"; d="scan'208";a="231896458" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 19 Nov 2021 05:52:59 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.87,247,1631602800"; d="scan'208";a="507905984" Received: from otc-skl-e5-server.sh.intel.com ([10.239.43.106]) by orsmga008.jf.intel.com with ESMTP; 19 Nov 2021 05:52:57 -0800 From: Wu Jianhua To: ffmpeg-devel@ffmpeg.org Date: Fri, 19 Nov 2021 21:52:42 +0800 Message-Id: <20211119135248.14518-5-jianhua.wu@intel.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20211119135248.14518-1-jianhua.wu@intel.com> References: <20211119135248.14518-1-jianhua.wu@intel.com> Subject: [FFmpeg-devel] [PATCH 05/11] avfilter/overlay_vulkan: use FF_ARRAY_ELEMS instead of magic number 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: Wu Jianhua MIME-Version: 1.0 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: ssZKCzwvliP4 Signed-off-by: Wu Jianhua --- libavfilter/vf_overlay_vulkan.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavfilter/vf_overlay_vulkan.c b/libavfilter/vf_overlay_vulkan.c index ab97cf2c17..705e92e268 100644 --- a/libavfilter/vf_overlay_vulkan.c +++ b/libavfilter/vf_overlay_vulkan.c @@ -146,7 +146,7 @@ static av_cold int init_filter(AVFilterContext *ctx) ff_vk_set_compute_shader_sizes(shd, CGROUPS); - RET(ff_vk_add_descriptor_set(vkctx, s->pl, shd, desc_i, 3, 0)); /* set 0 */ + RET(ff_vk_add_descriptor_set(vkctx, s->pl, shd, desc_i, FF_ARRAY_ELEMS(desc_i), 0)); /* set 0 */ RET(ff_vk_add_descriptor_set(vkctx, s->pl, shd, &desc_b, 1, 0)); /* set 1 */ GLSLD( overlay_noalpha );