From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTP id 741F946B33 for ; Mon, 3 Jul 2023 19:20:31 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 8F0FD68C57F; Mon, 3 Jul 2023 22:20:28 +0300 (EEST) Received: from iq.passwd.hu (iq.passwd.hu [217.27.212.140]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 4D00D68C57D for ; Mon, 3 Jul 2023 22:20:22 +0300 (EEST) Received: from localhost (localhost [127.0.0.1]) by iq.passwd.hu (Postfix) with ESMTP id 2DEA7E8BD6 for ; Mon, 3 Jul 2023 21:17:38 +0200 (CEST) X-Virus-Scanned: amavisd-new at passwd.hu Received: from iq.passwd.hu ([127.0.0.1]) by localhost (iq.passwd.hu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 8kShP6X6iw-P for ; Mon, 3 Jul 2023 21:17:36 +0200 (CEST) Received: from iq (iq [217.27.212.140]) by iq.passwd.hu (Postfix) with ESMTPS id 5F365E8BC8 for ; Mon, 3 Jul 2023 21:17:36 +0200 (CEST) Date: Mon, 3 Jul 2023 21:17:36 +0200 (CEST) From: Marton Balint To: FFmpeg development discussions and patches In-Reply-To: <1688408109-14381-5-git-send-email-dheitmueller@ltnglobal.com> Message-ID: References: <1688408109-14381-1-git-send-email-dheitmueller@ltnglobal.com> <1688408109-14381-5-git-send-email-dheitmueller@ltnglobal.com> MIME-Version: 1.0 Subject: Re: [FFmpeg-devel] [PATCH v2 4/5] mpegtsenc: Don't periodically announce PCR on SCTE-35 streams 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 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: On Mon, 3 Jul 2023, Devin Heitmueller wrote: > Changes were made between in the last two years to periodically > send PCR-only packets on all PIDs, but for cases where the stream > may send packets very infrequently (like SCTE-35), this results in > extra TR101290 errors because it fails the PCR interval test. > > I am not quite sure what the "right" fix should be for this, but > for now just disable all periodic sending of PCR-only packets on > SCTE-35 streams. Hmm, only one PID per service should generate PCR, and if there is a video stream in the service, then that is preferred for PCR generation. An SCTE stream should only get selected for PCR if there are no video streams in a service. Or are you seeing something else? And it is also strange that not sending PCR for any stream improves the PCR interval test, it should make it worse, because less PCRs are provided, no? Thanks, Marton > > Signed-off-by: Devin Heitmueller > --- > libavformat/mpegtsenc.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/libavformat/mpegtsenc.c b/libavformat/mpegtsenc.c > index c6cd1fd..ba60582 100644 > --- a/libavformat/mpegtsenc.c > +++ b/libavformat/mpegtsenc.c > @@ -1579,7 +1579,7 @@ static void mpegts_write_pes(AVFormatContext *s, AVStream *st, > int st2_index = i < st->index ? i : (i + 1 == s->nb_streams ? st->index : i + 1); > AVStream *st2 = s->streams[st2_index]; > MpegTSWriteStream *ts_st2 = st2->priv_data; > - if (ts_st2->pcr_period) { > + if (ts_st2->pcr_period && st2->codecpar->codec_id != AV_CODEC_ID_SCTE_35) { > if (pcr - ts_st2->last_pcr >= ts_st2->pcr_period) { > ts_st2->last_pcr = FFMAX(pcr - ts_st2->pcr_period, ts_st2->last_pcr + ts_st2->pcr_period); > if (st2 != st) { > -- > 1.8.3.1 > > _______________________________________________ > ffmpeg-devel mailing list > ffmpeg-devel@ffmpeg.org > https://ffmpeg.org/mailman/listinfo/ffmpeg-devel > > To unsubscribe, visit link above, or email > ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe". > _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".