From patchwork Fri Nov 22 01:48:03 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lance Wang X-Patchwork-Id: 16380 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 708B144730C for ; Fri, 22 Nov 2019 04:13:39 +0200 (EET) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 4E08368AE49; Fri, 22 Nov 2019 04:13:39 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mail-qv1-f66.google.com (mail-qv1-f66.google.com [209.85.219.66]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 2104D68AE48 for ; Fri, 22 Nov 2019 04:13:33 +0200 (EET) Received: by mail-qv1-f66.google.com with SMTP id cg2so2273322qvb.10 for ; Thu, 21 Nov 2019 18:13:33 -0800 (PST) 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=HCe5yVAyRTgxphYecq0A7r8XIBz/6ZNoiA91x50QwhA=; b=TGVBEYQs6uI/V3HSxrXsxNjmuqYBoxT+Rrt9ZXUefhdjXi5YIXq9PCpWu7IZf/vvz/ ZnPfQPAGa9HxuRrY4yhRbrh3lPMCMLYQvEjAswXgWqsMNGG2r7aBar5RavHwP+6U/K8p hkT0SljdeJwkWJY58+v20g6+X8LYZpeDLwQQs4oynb7VQ/RrvNhhffeI2rE9Q4NEyiqQ twMu+QpSZYCmhH26xvtq2ZqSZ6Dx5Ra12Xi8gs0mrc5IoQcjLJS7vzXDif/F76U6Q+JB 4r2R401hVW3inmCGr1feb/dYqPSQb6c7M2IEV1KeXCwNE4anuLKE2oH8NWjo/W9tK+7N Pmkw== 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=HCe5yVAyRTgxphYecq0A7r8XIBz/6ZNoiA91x50QwhA=; b=fIJRSGBXCrRKenrXfys8LDdaT8pPRZ7MqmtrsOfEN/K+thnlE3Ros01vCjaEiHj+Xd Oz/3Bkh4rKQEk0V6Adssec9MO1TmO77xrAIE5ML5RSqqzWTPmajHTVyNRJrIUGwnGrV+ qdR/UIfX9Ozmn3s9LZsL4j9ziKIhEawXGUstBqPpRUd3UNG0E8YdwkZH/q1Jczo5xM0S aV9EswdZS8ozPGr6rNQRlx9vqFibcmVU/TpsXNObIoqdKzwfFRBWNBZ1+k2aJbsXEjlC jWWBj+SWPfIUtKDYx9zAw6xRsjs0H2I49qlSe1ITADnkxyACsXbvKEnHw9AK86VF3ODp u1lg== X-Gm-Message-State: APjAAAU2EYyfIuW1wmCHvDjWs+l4bSyZo38zj5pL/YJ6qWl043KF4jsn FLtBjQng3JHv/H3N5ryziMv0ixsB X-Google-Smtp-Source: APXvYqyPSCSHeWSn10gvmscbaF/Kb+h6z8u+dv+F5xDNfs49HONR2SQXjHgq0WhYi5zjfaz5qWYI3A== X-Received: by 2002:a65:62d3:: with SMTP id m19mr12665377pgv.270.1574387293716; Thu, 21 Nov 2019 17:48:13 -0800 (PST) Received: from vpn.localdomain ([47.90.99.151]) by smtp.gmail.com with ESMTPSA id x2sm5244425pfj.90.2019.11.21.17.48.12 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 21 Nov 2019 17:48:13 -0800 (PST) From: lance.lmwang@gmail.com To: ffmpeg-devel@ffmpeg.org Date: Fri, 22 Nov 2019 09:48:03 +0800 Message-Id: <20191122014804.14701-2-lance.lmwang@gmail.com> X-Mailer: git-send-email 2.9.5 In-Reply-To: <20191122014804.14701-1-lance.lmwang@gmail.com> References: <20191122014804.14701-1-lance.lmwang@gmail.com> Subject: [FFmpeg-devel] [PATCH v2 2/3] bavfilter/vsrc_cellauto: Fix for random_seed type 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 Signed-off-by: Limin Wang --- libavfilter/vsrc_cellauto.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libavfilter/vsrc_cellauto.c b/libavfilter/vsrc_cellauto.c index 7a6d9659f7..c75460334e 100644 --- a/libavfilter/vsrc_cellauto.c +++ b/libavfilter/vsrc_cellauto.c @@ -50,7 +50,7 @@ typedef struct CellAutoContext { uint64_t pts; AVRational frame_rate; double random_fill_ratio; - uint32_t random_seed; + int64_t random_seed; int stitch, scroll, start_full; int64_t generation; ///< the generation number, starting from 0 AVLFG lfg; @@ -72,8 +72,8 @@ static const AVOption cellauto_options[] = { { "rule", "set rule", OFFSET(rule), AV_OPT_TYPE_INT, {.i64 = 110}, 0, 255, FLAGS }, { "random_fill_ratio", "set fill ratio for filling initial grid randomly", OFFSET(random_fill_ratio), AV_OPT_TYPE_DOUBLE, {.dbl = 1/M_PHI}, 0, 1, FLAGS }, { "ratio", "set fill ratio for filling initial grid randomly", OFFSET(random_fill_ratio), AV_OPT_TYPE_DOUBLE, {.dbl = 1/M_PHI}, 0, 1, FLAGS }, - { "random_seed", "set the seed for filling the initial grid randomly", OFFSET(random_seed), AV_OPT_TYPE_INT, {.i64 = -1}, -1, UINT32_MAX, FLAGS }, - { "seed", "set the seed for filling the initial grid randomly", OFFSET(random_seed), AV_OPT_TYPE_INT, {.i64 = -1}, -1, UINT32_MAX, FLAGS }, + { "random_seed", "set the seed for filling the initial grid randomly", OFFSET(random_seed), AV_OPT_TYPE_INT64, {.i64 = -1}, -1, UINT32_MAX, FLAGS }, + { "seed", "set the seed for filling the initial grid randomly", OFFSET(random_seed), AV_OPT_TYPE_INT64, {.i64 = -1}, -1, UINT32_MAX, FLAGS }, { "scroll", "scroll pattern downward", OFFSET(scroll), AV_OPT_TYPE_BOOL, {.i64 = 1}, 0, 1, FLAGS }, { "start_full", "start filling the whole video", OFFSET(start_full), AV_OPT_TYPE_BOOL, {.i64 = 0}, 0, 1, FLAGS }, { "full", "start filling the whole video", OFFSET(start_full), AV_OPT_TYPE_BOOL, {.i64 = 1}, 0, 1, FLAGS },