From patchwork Sat Mar 11 17:58:56 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Muhammad Faiz X-Patchwork-Id: 2888 Delivered-To: ffmpegpatchwork@gmail.com Received: by 10.103.50.79 with SMTP id y76csp560712vsy; Sat, 11 Mar 2017 10:06:36 -0800 (PST) X-Received: by 10.223.165.17 with SMTP id i17mr22535578wrb.70.1489255596399; Sat, 11 Mar 2017 10:06:36 -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 u4si4205695wma.15.2017.03.11.10.06.35; Sat, 11 Mar 2017 10:06:36 -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=@gmail.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=gmail.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 785DB689A6E; Sat, 11 Mar 2017 20:06:18 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mail-pg0-f65.google.com (mail-pg0-f65.google.com [74.125.83.65]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 3B26F689A30 for ; Sat, 11 Mar 2017 20:06:12 +0200 (EET) Received: by mail-pg0-f65.google.com with SMTP id b5so13745729pgg.1 for ; Sat, 11 Mar 2017 10:06:27 -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; bh=ESYgZm63YrI8ughbwaaZHtpxf378J4Dc0s6Wjn9IcT0=; b=ekvCw2xgDZx4zY5Sq8iuX8k4Tc26xupDO9yl8BsyW/oESi0w1p0yB0hiik989At5z5 ojO9L558eabGWdRoeWjKf2ZguLY9iKVnXuCPhzoEIEgk79tS4lZ+mZt5s41R7zQ0uyIC AZcbeuA8VppWwN7KVZRr4f1zyiodWNXw0/2Ylw5teynoMkYy42LGeKpT+T14DxjgvkaO WvkWOUidCLOFn7gwyOtQgbRBivQfoYx/bqfHFNg4WF9o6rO/jcohqhBVYm1hZmontxId bKpJFRuRz/C8pkQhzP8jk56h6gDcul6aRbJD/5lJMN0LO+tghfnj5xyKD3lT42yyknRY ILyQ== 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; bh=ESYgZm63YrI8ughbwaaZHtpxf378J4Dc0s6Wjn9IcT0=; b=aP7qvkd9DPvoSnkjPUEbgTxe3ORRXU4S1jIaefasPTjoo6QCiig8Jm83r3edSNe/Yg FJD3iJyzOL0R21YaBY1E9xbiLhEztFHg3ApVQ39UvxuJkQCjtn3CWQZ+fOB1/wUVOVsT qdIHNRXvOMt2ej6KJOhrYEGEH4GLjvLhB2UaJOaAr+XP7Ke9otiJg898FUJ+R9bZQSCh Ty6OQ1GS3cut10U9iNSm+B636LXWtu25ZOfNwT0UNVTiS3KbPhTSQLYNG0+6mtGc2kG5 sk8377ELynQ8SaVn/LWwzNc4KD2tpvcIeokObhpvYIRwpcbrsa4/I7c5X981TA9CWxwg fIbw== X-Gm-Message-State: AMke39nP3aMXt7TherSlYwDfcBY+927aWm+uIVWuSlnVjYjegyGtYKN8Dkx8m89BHmQxMQ== X-Received: by 10.84.233.206 with SMTP id m14mr34949205pln.153.1489255152288; Sat, 11 Mar 2017 09:59:12 -0800 (PST) Received: from localhost.localdomain ([114.121.247.219]) by smtp.gmail.com with ESMTPSA id c11sm25283837pfe.68.2017.03.11.09.59.09 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 11 Mar 2017 09:59:11 -0800 (PST) From: Muhammad Faiz To: ffmpeg-devel@ffmpeg.org Date: Sun, 12 Mar 2017 00:58:56 +0700 Message-Id: <20170311175856.2048-1-mfcc64@gmail.com> X-Mailer: git-send-email 2.9.3 Subject: [FFmpeg-devel] [PATCH v2] swresample/swresample: do not reset tsf on swr_alloc_set_opts 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: Muhammad Faiz MIME-Version: 1.0 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" so tsf option in aresample will have effect previously tsf/internal_sample_format had no effect fate is updated s32p previously used fltp internally dblp previously used fltp/dblp internally Signed-off-by: Muhammad Faiz --- libswresample/swresample.c | 3 -- tests/fate/libswresample.mak | 80 ++++++++++++++++++++++---------------------- 2 files changed, 40 insertions(+), 43 deletions(-) diff --git a/libswresample/swresample.c b/libswresample/swresample.c index dea6139..f2e6600 100644 --- a/libswresample/swresample.c +++ b/libswresample/swresample.c @@ -84,9 +84,6 @@ struct SwrContext *swr_alloc_set_opts(struct SwrContext *s, if (av_opt_set_int(s, "isr", in_sample_rate, 0) < 0) goto fail; - if (av_opt_set_int(s, "tsf", AV_SAMPLE_FMT_NONE, 0) < 0) - goto fail; - if (av_opt_set_int(s, "ich", av_get_channel_layout_nb_channels(s-> user_in_ch_layout), 0) < 0) goto fail; diff --git a/tests/fate/libswresample.mak b/tests/fate/libswresample.mak index 78dbde7..d9e0fa9 100644 --- a/tests/fate/libswresample.mak +++ b/tests/fate/libswresample.mak @@ -218,28 +218,28 @@ fate-swr-resample-s32p-2626-8000: SIZE_TOLERANCE = 31512 - 20482 fate-swr-resample-s32p-2626-96000: CMP_TARGET = 1393.00 fate-swr-resample-s32p-2626-96000: SIZE_TOLERANCE = 31512 - 20480 -fate-swr-resample-s32p-44100-2626: CMP_TARGET = 185.82 +fate-swr-resample-s32p-44100-2626: CMP_TARGET = 185.81 fate-swr-resample-s32p-44100-2626: SIZE_TOLERANCE = 529200 - 20490 -fate-swr-resample-s32p-44100-48000: CMP_TARGET = 9.69 +fate-swr-resample-s32p-44100-48000: CMP_TARGET = 9.70 fate-swr-resample-s32p-44100-48000: SIZE_TOLERANCE = 529200 - 20482 fate-swr-resample-s32p-44100-8000: CMP_TARGET = 75.45 fate-swr-resample-s32p-44100-8000: SIZE_TOLERANCE = 529200 - 20486 -fate-swr-resample-s32p-44100-96000: CMP_TARGET = 11.46 +fate-swr-resample-s32p-44100-96000: CMP_TARGET = 11.47 fate-swr-resample-s32p-44100-96000: SIZE_TOLERANCE = 529200 - 20482 -fate-swr-resample-s32p-48000-2626: CMP_TARGET = 456.51 +fate-swr-resample-s32p-48000-2626: CMP_TARGET = 456.49 fate-swr-resample-s32p-48000-2626: SIZE_TOLERANCE = 576000 - 20510 -fate-swr-resample-s32p-48000-44100: CMP_TARGET = 1.00 +fate-swr-resample-s32p-48000-44100: CMP_TARGET = 1.12 fate-swr-resample-s32p-48000-44100: SIZE_TOLERANCE = 576000 - 20480 -fate-swr-resample-s32p-48000-8000: CMP_TARGET = 62.38 +fate-swr-resample-s32p-48000-8000: CMP_TARGET = 62.37 fate-swr-resample-s32p-48000-8000: SIZE_TOLERANCE = 576000 - 20484 -fate-swr-resample-s32p-48000-96000: CMP_TARGET = 0.47 +fate-swr-resample-s32p-48000-96000: CMP_TARGET = 0.85 fate-swr-resample-s32p-48000-96000: SIZE_TOLERANCE = 576000 - 20480 fate-swr-resample-s32p-8000-2626: CMP_TARGET = 2503.33 @@ -248,22 +248,22 @@ fate-swr-resample-s32p-8000-2626: SIZE_TOLERANCE = 96000 - 20486 fate-swr-resample-s32p-8000-44100: CMP_TARGET = 15.09 fate-swr-resample-s32p-8000-44100: SIZE_TOLERANCE = 96000 - 20480 -fate-swr-resample-s32p-8000-48000: CMP_TARGET = 14.69 +fate-swr-resample-s32p-8000-48000: CMP_TARGET = 14.68 fate-swr-resample-s32p-8000-48000: SIZE_TOLERANCE = 96000 - 20480 fate-swr-resample-s32p-8000-96000: CMP_TARGET = 13.81 fate-swr-resample-s32p-8000-96000: SIZE_TOLERANCE = 96000 - 20480 -fate-swr-resample-s32p-96000-2626: CMP_TARGET = 675.07 +fate-swr-resample-s32p-96000-2626: CMP_TARGET = 675.05 fate-swr-resample-s32p-96000-2626: SIZE_TOLERANCE = 1152000 - 20474 -fate-swr-resample-s32p-96000-44100: CMP_TARGET = 1.44 +fate-swr-resample-s32p-96000-44100: CMP_TARGET = 1.54 fate-swr-resample-s32p-96000-44100: SIZE_TOLERANCE = 1152000 - 20480 -fate-swr-resample-s32p-96000-48000: CMP_TARGET = 0.99 +fate-swr-resample-s32p-96000-48000: CMP_TARGET = 1.21 fate-swr-resample-s32p-96000-48000: SIZE_TOLERANCE = 1152000 - 20480 -fate-swr-resample-s32p-96000-8000: CMP_TARGET = 58.57 +fate-swr-resample-s32p-96000-8000: CMP_TARGET = 58.59 fate-swr-resample-s32p-96000-8000: SIZE_TOLERANCE = 1152000 - 20496 @@ -440,7 +440,7 @@ fate-swr-resample_exact-dblp-8000-96000: SIZE_TOLERANCE = 96000 - 20480 fate-swr-resample_exact-dblp-96000-2626: CMP_TARGET = 675.07 fate-swr-resample_exact-dblp-96000-2626: SIZE_TOLERANCE = 1152000 - 20474 -fate-swr-resample_exact-dblp-96000-44100: CMP_TARGET = 1.23 +fate-swr-resample_exact-dblp-96000-44100: CMP_TARGET = 1.24 fate-swr-resample_exact-dblp-96000-44100: SIZE_TOLERANCE = 1152000 - 20480 fate-swr-resample_exact-dblp-96000-48000: CMP_TARGET = 0.99 @@ -581,52 +581,52 @@ fate-swr-resample_exact-s32p-2626-8000: SIZE_TOLERANCE = 31512 - 20482 fate-swr-resample_exact-s32p-2626-96000: CMP_TARGET = 1393.00 fate-swr-resample_exact-s32p-2626-96000: SIZE_TOLERANCE = 31512 - 20480 -fate-swr-resample_exact-s32p-44100-2626: CMP_TARGET = 185.82 +fate-swr-resample_exact-s32p-44100-2626: CMP_TARGET = 185.81 fate-swr-resample_exact-s32p-44100-2626: SIZE_TOLERANCE = 529200 - 20490 -fate-swr-resample_exact-s32p-44100-48000: CMP_TARGET = 9.64 +fate-swr-resample_exact-s32p-44100-48000: CMP_TARGET = 9.66 fate-swr-resample_exact-s32p-44100-48000: SIZE_TOLERANCE = 529200 - 20482 -fate-swr-resample_exact-s32p-44100-8000: CMP_TARGET = 75.38 +fate-swr-resample_exact-s32p-44100-8000: CMP_TARGET = 75.37 fate-swr-resample_exact-s32p-44100-8000: SIZE_TOLERANCE = 529200 - 20486 -fate-swr-resample_exact-s32p-44100-96000: CMP_TARGET = 11.45 +fate-swr-resample_exact-s32p-44100-96000: CMP_TARGET = 11.46 fate-swr-resample_exact-s32p-44100-96000: SIZE_TOLERANCE = 529200 - 20482 -fate-swr-resample_exact-s32p-48000-2626: CMP_TARGET = 456.51 +fate-swr-resample_exact-s32p-48000-2626: CMP_TARGET = 456.49 fate-swr-resample_exact-s32p-48000-2626: SIZE_TOLERANCE = 576000 - 20510 -fate-swr-resample_exact-s32p-48000-44100: CMP_TARGET = 0.23 +fate-swr-resample_exact-s32p-48000-44100: CMP_TARGET = 0.74 fate-swr-resample_exact-s32p-48000-44100: SIZE_TOLERANCE = 576000 - 20480 -fate-swr-resample_exact-s32p-48000-8000: CMP_TARGET = 62.36 +fate-swr-resample_exact-s32p-48000-8000: CMP_TARGET = 62.35 fate-swr-resample_exact-s32p-48000-8000: SIZE_TOLERANCE = 576000 - 20484 -fate-swr-resample_exact-s32p-48000-96000: CMP_TARGET = 0.47 +fate-swr-resample_exact-s32p-48000-96000: CMP_TARGET = 0.85 fate-swr-resample_exact-s32p-48000-96000: SIZE_TOLERANCE = 576000 - 20480 fate-swr-resample_exact-s32p-8000-2626: CMP_TARGET = 2503.33 fate-swr-resample_exact-s32p-8000-2626: SIZE_TOLERANCE = 96000 - 20486 -fate-swr-resample_exact-s32p-8000-44100: CMP_TARGET = 14.59 +fate-swr-resample_exact-s32p-8000-44100: CMP_TARGET = 14.61 fate-swr-resample_exact-s32p-8000-44100: SIZE_TOLERANCE = 96000 - 20480 -fate-swr-resample_exact-s32p-8000-48000: CMP_TARGET = 14.50 +fate-swr-resample_exact-s32p-8000-48000: CMP_TARGET = 14.52 fate-swr-resample_exact-s32p-8000-48000: SIZE_TOLERANCE = 96000 - 20480 fate-swr-resample_exact-s32p-8000-96000: CMP_TARGET = 13.62 fate-swr-resample_exact-s32p-8000-96000: SIZE_TOLERANCE = 96000 - 20480 -fate-swr-resample_exact-s32p-96000-2626: CMP_TARGET = 675.07 +fate-swr-resample_exact-s32p-96000-2626: CMP_TARGET = 675.05 fate-swr-resample_exact-s32p-96000-2626: SIZE_TOLERANCE = 1152000 - 20474 -fate-swr-resample_exact-s32p-96000-44100: CMP_TARGET = 1.23 +fate-swr-resample_exact-s32p-96000-44100: CMP_TARGET = 1.41 fate-swr-resample_exact-s32p-96000-44100: SIZE_TOLERANCE = 1152000 - 20480 -fate-swr-resample_exact-s32p-96000-48000: CMP_TARGET = 0.99 +fate-swr-resample_exact-s32p-96000-48000: CMP_TARGET = 1.21 fate-swr-resample_exact-s32p-96000-48000: SIZE_TOLERANCE = 1152000 - 20480 -fate-swr-resample_exact-s32p-96000-8000: CMP_TARGET = 58.52 +fate-swr-resample_exact-s32p-96000-8000: CMP_TARGET = 58.54 fate-swr-resample_exact-s32p-96000-8000: SIZE_TOLERANCE = 1152000 - 20496 define ARESAMPLE_EXACT_ASYNC @@ -700,7 +700,7 @@ fate-swr-resample_exact_async-s32p-44100-48000: SIZE_TOLERANCE = 529200 - 20300 fate-swr-resample_exact_async-s32p-44100-8000: CMP_TARGET = 4022.87 fate-swr-resample_exact_async-s32p-44100-8000: SIZE_TOLERANCE = 529200 - 20310 -fate-swr-resample_exact_async-s32p-48000-44100: CMP_TARGET = 1923.97 +fate-swr-resample_exact_async-s32p-48000-44100: CMP_TARGET = 1923.96 fate-swr-resample_exact_async-s32p-48000-44100: SIZE_TOLERANCE = 576000 - 20298 fate-swr-resample_exact_async-s32p-48000-8000: CMP_TARGET = 2592.00 @@ -709,7 +709,7 @@ fate-swr-resample_exact_async-s32p-48000-8000: SIZE_TOLERANCE = 576000 - 20304 fate-swr-resample_exact_async-s32p-8000-44100: CMP_TARGET = 11187.24 fate-swr-resample_exact_async-s32p-8000-44100: SIZE_TOLERANCE = 96000 - 20344 -fate-swr-resample_exact_async-s32p-8000-48000: CMP_TARGET = 11326.80 +fate-swr-resample_exact_async-s32p-8000-48000: CMP_TARGET = 11326.79 fate-swr-resample_exact_async-s32p-8000-48000: SIZE_TOLERANCE = 96000 - 20344 define ARESAMPLE_EXACT_LIN @@ -777,22 +777,22 @@ fate-swr-resample_exact_lin-s16p-8000-44100: SIZE_TOLERANCE = 96000 - 20480 fate-swr-resample_exact_lin-s16p-8000-48000: CMP_TARGET = 14.54 fate-swr-resample_exact_lin-s16p-8000-48000: SIZE_TOLERANCE = 96000 - 20480 -fate-swr-resample_exact_lin-s32p-44100-48000: CMP_TARGET = 9.64 +fate-swr-resample_exact_lin-s32p-44100-48000: CMP_TARGET = 9.66 fate-swr-resample_exact_lin-s32p-44100-48000: SIZE_TOLERANCE = 529200 - 20482 -fate-swr-resample_exact_lin-s32p-44100-8000: CMP_TARGET = 75.38 +fate-swr-resample_exact_lin-s32p-44100-8000: CMP_TARGET = 75.37 fate-swr-resample_exact_lin-s32p-44100-8000: SIZE_TOLERANCE = 529200 - 20486 -fate-swr-resample_exact_lin-s32p-48000-44100: CMP_TARGET = 0.23 +fate-swr-resample_exact_lin-s32p-48000-44100: CMP_TARGET = 0.74 fate-swr-resample_exact_lin-s32p-48000-44100: SIZE_TOLERANCE = 576000 - 20480 -fate-swr-resample_exact_lin-s32p-48000-8000: CMP_TARGET = 62.36 +fate-swr-resample_exact_lin-s32p-48000-8000: CMP_TARGET = 62.35 fate-swr-resample_exact_lin-s32p-48000-8000: SIZE_TOLERANCE = 576000 - 20484 -fate-swr-resample_exact_lin-s32p-8000-44100: CMP_TARGET = 14.59 +fate-swr-resample_exact_lin-s32p-8000-44100: CMP_TARGET = 14.61 fate-swr-resample_exact_lin-s32p-8000-44100: SIZE_TOLERANCE = 96000 - 20480 -fate-swr-resample_exact_lin-s32p-8000-48000: CMP_TARGET = 14.50 +fate-swr-resample_exact_lin-s32p-8000-48000: CMP_TARGET = 14.52 fate-swr-resample_exact_lin-s32p-8000-48000: SIZE_TOLERANCE = 96000 - 20480 define ARESAMPLE_EXACT_LIN_ASYNC @@ -818,7 +818,7 @@ fate-swr-resample_exact_lin_async-dblp-48000-44100: SIZE_TOLERANCE = 576000 - 20 fate-swr-resample_exact_lin_async-dblp-48000-8000: CMP_TARGET = 2591.72 fate-swr-resample_exact_lin_async-dblp-48000-8000: SIZE_TOLERANCE = 576000 - 20304 -fate-swr-resample_exact_lin_async-dblp-8000-44100: CMP_TARGET = 11187.25 +fate-swr-resample_exact_lin_async-dblp-8000-44100: CMP_TARGET = 11187.24 fate-swr-resample_exact_lin_async-dblp-8000-44100: SIZE_TOLERANCE = 96000 - 20344 fate-swr-resample_exact_lin_async-dblp-8000-48000: CMP_TARGET = 11326.80 @@ -863,19 +863,19 @@ fate-swr-resample_exact_lin_async-s16p-8000-48000: SIZE_TOLERANCE = 96000 - 2034 fate-swr-resample_exact_lin_async-s32p-44100-48000: CMP_TARGET = 7791.72 fate-swr-resample_exact_lin_async-s32p-44100-48000: SIZE_TOLERANCE = 529200 - 20300 -fate-swr-resample_exact_lin_async-s32p-44100-8000: CMP_TARGET = 4023.01 +fate-swr-resample_exact_lin_async-s32p-44100-8000: CMP_TARGET = 4023.02 fate-swr-resample_exact_lin_async-s32p-44100-8000: SIZE_TOLERANCE = 529200 - 20310 -fate-swr-resample_exact_lin_async-s32p-48000-44100: CMP_TARGET = 1923.79 +fate-swr-resample_exact_lin_async-s32p-48000-44100: CMP_TARGET = 1923.77 fate-swr-resample_exact_lin_async-s32p-48000-44100: SIZE_TOLERANCE = 576000 - 20298 -fate-swr-resample_exact_lin_async-s32p-48000-8000: CMP_TARGET = 2591.72 +fate-swr-resample_exact_lin_async-s32p-48000-8000: CMP_TARGET = 2591.71 fate-swr-resample_exact_lin_async-s32p-48000-8000: SIZE_TOLERANCE = 576000 - 20304 fate-swr-resample_exact_lin_async-s32p-8000-44100: CMP_TARGET = 11187.25 fate-swr-resample_exact_lin_async-s32p-8000-44100: SIZE_TOLERANCE = 96000 - 20344 -fate-swr-resample_exact_lin_async-s32p-8000-48000: CMP_TARGET = 11326.80 +fate-swr-resample_exact_lin_async-s32p-8000-48000: CMP_TARGET = 11326.81 fate-swr-resample_exact_lin_async-s32p-8000-48000: SIZE_TOLERANCE = 96000 - 20344 $(call CROSS_TEST,$(SAMPLERATES),ARESAMPLE,s16p,s16le,s16)