From patchwork Tue Oct 11 11:30:30 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Josh Dekker X-Patchwork-Id: 954 Delivered-To: ffmpegpatchwork@gmail.com Received: by 10.103.140.66 with SMTP id o63csp255549vsd; Tue, 11 Oct 2016 04:30:45 -0700 (PDT) X-Received: by 10.194.109.42 with SMTP id hp10mr4289550wjb.24.1476185445854; Tue, 11 Oct 2016 04:30:45 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id u3si4330663wjx.219.2016.10.11.04.30.44; Tue, 11 Oct 2016 04:30:45 -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=@itanimul.li; dkim=neutral (body hash did not verify) header.i=@messagingengine.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 Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id BD8A6689B13; Tue, 11 Oct 2016 14:30:42 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from out5-smtp.messagingengine.com (out5-smtp.messagingengine.com [66.111.4.29]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 66CFE687ED6 for ; Tue, 11 Oct 2016 14:30:36 +0300 (EEST) Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailout.nyi.internal (Postfix) with ESMTP id 142A5209F6 for ; Tue, 11 Oct 2016 07:30:34 -0400 (EDT) Received: from frontend1 ([10.202.2.160]) by compute7.internal (MEProxy); Tue, 11 Oct 2016 07:30:34 -0400 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=itanimul.li; h= date:from:message-id:subject:to:x-sasl-enc:x-sasl-enc; s=mesmtp; bh=EJApwX3e9ig5UFWYWT1zERBEeZs=; b=V6rKwmVznlmGoOh3yoSsc0TcgUKL LNoeYN0U668lknlfvIsT99dLQbRD/+cqLvu9gDhWtoXT1zUu2ZJ6MX0qHrcUOfCL fXG6sX03OqBDVHFxdmLPdSdQ1zdEzgTr7Gef2H6oXm6pV7mBu+y6giALHf3qkLQH tzm+l1JHbIal37A= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=date:from:message-id:subject:to :x-sasl-enc:x-sasl-enc; s=smtpout; bh=EJApwX3e9ig5UFWYWT1zERBEeZ s=; b=lBaGqK30UwKexPgzaWEG6gpTcEshZtTncYEP+ukIDjeArv8Bg/L5t/QFsZ a+jfmk22LMQF5vCzDTrKMjfifcp/3RXX1Jx5y5YPqQDTtpJfp90zhdka2XAJUifR y4vK+jM5RkHDyRx5pRKdpQ3phZVWOn/Pl8XQZmkO4anEG6ySg= X-Sasl-enc: kQUc1NbJx2wr3/jtjzUi3ciSM3SmlA4DidG37cGf9QWx 1476185433 Received: from localhost (cpc75394-sotn16-2-0-cust168.15-1.cable.virginm.net [82.22.8.169]) by mail.messagingengine.com (Postfix) with ESMTPA id 73EA5F2985 for ; Tue, 11 Oct 2016 07:30:33 -0400 (EDT) From: Josh de Kock To: ffmpeg-devel@ffmpeg.org Date: Tue, 11 Oct 2016 12:30:30 +0100 Message-Id: <20161011113030.76374-1-josh@itanimul.li> X-Mailer: git-send-email 2.8.4 (Apple Git-73) Subject: [FFmpeg-devel] [PATCH] lavf/movenc: suggest video_track_timescale for invalid timescale 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 MIME-Version: 1.0 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Fixes ticket #5882. While it doesn't automatically set the timescale for the user as that would destroy data without prompt, it will tell the user how they could set the timescale (as this is mostly likely what they want). Signed-off-by: Josh de Kock --- libavformat/movenc.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libavformat/movenc.c b/libavformat/movenc.c index d7c7158..1f4f2b0 100644 --- a/libavformat/movenc.c +++ b/libavformat/movenc.c @@ -5681,7 +5681,9 @@ static int mov_write_header(AVFormatContext *s) av_log(s, AV_LOG_WARNING, "WARNING codec timebase is very high. If duration is too long,\n" "file may not be playable by quicktime. Specify a shorter timebase\n" - "or choose different container.\n"); + "or choose different container. You may find the -video_track_timescale\n" + "flag useful to forcibly set a specific timescale. Ex. 30000/1001 FPS\n" + "would be -video_track_timescale 30000.\n"); if (track->mode == MODE_MOV && track->par->codec_id == AV_CODEC_ID_RAWVIDEO && track->tag == MKTAG('r','a','w',' ')) {