From patchwork Thu Sep 26 14:57:42 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lance Wang X-Patchwork-Id: 15309 Return-Path: X-Original-To: patchwork@ffaux-bg.ffmpeg.org Delivered-To: patchwork@ffaux-bg.ffmpeg.org Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by ffaux.localdomain (Postfix) with ESMTP id 89DBF44A6CD for ; Thu, 26 Sep 2019 17:57:55 +0300 (EEST) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 68BBB68994B; Thu, 26 Sep 2019 17:57:55 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mail-pg1-f193.google.com (mail-pg1-f193.google.com [209.85.215.193]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id E22F66881D2 for ; Thu, 26 Sep 2019 17:57:48 +0300 (EEST) Received: by mail-pg1-f193.google.com with SMTP id w10so1710391pgj.7 for ; Thu, 26 Sep 2019 07:57:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=JAKGfX4NQvlVy/ByHQNHPQCzzhWmXcV9Fswf37rxReY=; b=KycjcK3fXaHoDzBF0cjfrdtuR9WPjaAAzhHsxXC/pzRA2T/dQk61e7otykvz23KJM1 lmxLWXf5nrx5vYSv1CFb79Ru1rItzTfY2musrrfi5QyMyXglbUKk5zRuREtb99zsbO3X 12V1nTA5kzzRF5TWYKl5O/UeA/HuQvVS6qR42/fm0A+ZL5o1ErVlAfF+Td2ltdN6fNcP Kr6ckIcBqRuPFMLXLSO9NMO3rtPDLJ3zyE9Eo5CLo4j7tY+55AV4U21H2kfGdya+mqGr 8WBwXNl/DIyCF9ceWBtX5b1qlbpZ9+pbsyHs7/ThwhSkhrEJCS/fBG1UBe+rBB1d/c7e t/yA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=JAKGfX4NQvlVy/ByHQNHPQCzzhWmXcV9Fswf37rxReY=; b=RSb1w/4W59kRM9L8EF8c6r0oVWHpKKTRmqFFdQhDBPfAuq5zxrF9g7Z/1IHKWpONMK C49mr/2fAGTCfgJD6HNEiGvuNT9Rl3LfvyngT7Kow4zxpVgloVL0POzrkrDE6FUOwPre 0Lf4iogcdkJiz4QoIwdVM9Qd1TBChHYlGsKGJwR7ux7b/qocbozBizlD15d0mzLOmfUF nFh5B/svtZn+AV5FdPLS/o1gk7uMy2tuaouk96swKqMURH6by1m7Kh1T0tPMKFP5WvpH xJIG9r4WejGwuRrCaYhbVMMrCrsRPtT1yC3uNbMrIIwTCg3Wa4isiXb+05zuoIaOgtuH 8JHA== X-Gm-Message-State: APjAAAU3dHHZSGp8k6UQlbKKlN/cHXEzoS1zP2ydg8qLx1v9UMRVG9zr mRTWoja8timtdFTZcpANnW+sysaN X-Google-Smtp-Source: APXvYqzWBP1abjKT88JUAeBRfIbuYWFWsjOiOnSKMQjXOxy5MBWsb4p3eOeFvLoSsat+h/5BDD4x6g== X-Received: by 2002:a62:4d45:: with SMTP id a66mr4216549pfb.24.1569509866725; Thu, 26 Sep 2019 07:57:46 -0700 (PDT) Received: from vpn.localdomain ([47.90.99.151]) by smtp.gmail.com with ESMTPSA id y28sm2868771pfq.48.2019.09.26.07.57.45 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 26 Sep 2019 07:57:46 -0700 (PDT) From: lance.lmwang@gmail.com To: ffmpeg-devel@ffmpeg.org Date: Thu, 26 Sep 2019 22:57:42 +0800 Message-Id: <20190926145742.28621-1-lance.lmwang@gmail.com> X-Mailer: git-send-email 2.9.5 In-Reply-To: <20190919054314.32694-1-lance.lmwang@gmail.com> References: <20190919054314.32694-1-lance.lmwang@gmail.com> Subject: [FFmpeg-devel] [PATCH v6] doc/filters: add 4x4 layout example for xstack filter X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.20 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: Limin Wang MIME-Version: 1.0 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" From: Limin Wang Reviewed-by: Gyan Signed-off-by: Limin Wang --- doc/filters.texi | 55 ++++++++++++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 52 insertions(+), 3 deletions(-) diff --git a/doc/filters.texi b/doc/filters.texi index e6f8bf0..581a96b 100644 --- a/doc/filters.texi +++ b/doc/filters.texi @@ -19060,6 +19060,13 @@ terminates. Default value is 0. @itemize @item Display 4 inputs into 2x2 grid. + +Below is the 4 inputs position: +@example +input1(0, 0) | input3(w0, 0) +input2(0, h0) | input4(w0, h0) +@end example + Note that if inputs are of different sizes unused gaps might appear, as not all of output video is used. @example @@ -19068,6 +19075,15 @@ xstack=inputs=4:layout=0_0|0_h0|w0_0|w0_h0 @item Display 4 inputs into 1x4 grid. + +Below is the 4 inputs position: +@example +input1(0, 0) +input2(0, h0) +input3(0, h0+h1) +input4(0, h0+h1+h2) +@end example + Note that if inputs are of different sizes unused gaps might appear, as not all of output video is used. @example @@ -19076,11 +19092,44 @@ xstack=inputs=4:layout=0_0|0_h0|0_h0+h1|0_h0+h1+h2 @item Display 9 inputs into 3x3 grid. -Note that if inputs are of different sizes unused gaps might appear, -as not all of output video is used. + +Below is the 9 inputs position: @example -xstack=inputs=9:layout=w3_0|w3_h0+h2|w3_h0|0_h4|0_0|w3+w1_0|0_h1+h2|w3+w1_h0|w3+w1_h1+h2 +input1(0, 0) | input4(w0, 0) | input7(w0+w3, 0) +input2(0, h0) | input5(w0, h0) | input8(w0+w3, h0) +input3(0, h0+h1) | input6(w0, h0+h1) | input9(w0+w3, h0+h1) @end example + +Note that if the input size is different, there may be unused gaps or +overlaps. For example, if the height of input4 is greater than input1, +input5 will overlaid the top of input4, if the width of input5 is less +than input4, then input5 will have unused gaps. + +@example +xstack=inputs=9:layout=0_0|0_h0|0_h0+h1|w0_0|w0_h0|w0_h0+h1|w0+w3_0|w0+w3_h0|w0+w3_h0+h1 +@end example + +@item +Display 16 inputs into 4x4 grid. + +Below is the 16 inputs position: +@example +input1(0, 0) | input5(w0, 0) | input9 (w0+w4, 0) | input13(w0+w4+w8, 0) +input2(0, h0) | input6(w0, h0) | input10(w0+w4, h0) | input14(w0+w4+w8, h0) +input3(0, h0+h1) | input7(w0, h0+h1) | input11(w0+w4, h0+h1) | input15(w0+w4+w8, h0+h1) +input4(0, h0+h1+h2)| input8(w0, h0+h1+h2)| input12(w0+w4, h0+h1+h2)| input16(w0+w4+w8, h0+h1+h2) +@end example + +Note that if the input size is different, there may be unused gaps or +overlaps. For example, if the height of input5 is greater than input1, +input6 will overlaid the top of input5, if the width of input6 is less +than input5, then input6 will have unused gaps. + +@example +xstack=inputs=16:layout=0_0|0_h0|0_h0+h1|0_h0+h1+h2|w0_0|w0_h0|w0_h0+h1|w0_h0+h1+h2|w0+w4_0| +w0+w4_h0|w0+w4_h0+h1|w0+w4_h0+h1+h2|w0+w4+w8_0|w0+w4+w8_h0|w0+w4+w8_h0+h1|w0+w4+w8_h0+h1+h2 +@end example + @end itemize @anchor{yadif}