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 80A5A49715 for ; Tue, 19 Mar 2024 14:36:10 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 250E568D391; Tue, 19 Mar 2024 16:36:08 +0200 (EET) Received: from mail-ej1-f43.google.com (mail-ej1-f43.google.com [209.85.218.43]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id D93CD68D33E for ; Tue, 19 Mar 2024 16:36:00 +0200 (EET) Received: by mail-ej1-f43.google.com with SMTP id a640c23a62f3a-a46cc947929so254568566b.1 for ; Tue, 19 Mar 2024 07:36:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1710858959; x=1711463759; darn=ffmpeg.org; h=user-agent:in-reply-to:content-disposition:mime-version:references :mail-followup-to:message-id:subject:cc:to:from:date:from:to:cc :subject:date:message-id:reply-to; bh=luChDqVSAAc4fb7iffDdxPiZjioqHyEFcgfo6spQKkk=; b=eSM31d/M2Sg/8Hy4OGM1BPNqAjrEWqv3P/rpa95QbZs5QBYrw7LlHQCf2d8tQ47y6s XHzJt6rFiSemExN8BuZChghEXsZXRzWJ6cYHJohI/B3xawh79FoYYZ2aurpLNvG35mle H3gOnjUVyZYHl/SMul/6kY2c+mrcIoQMoHyzQ1NzYAoo41vqlMOjGghRhQRVpFV//JWC b80NMB3yGbZjsFp0MZF0crObVO+Txw+SqE1rNk3G4wxIRUu8mNi79NrilNfGNXb32Gjj ODNjvQqiEhrqwLQlkNakDvTCPU51Z547L42/W/y+HEi+5Oe70FYLARLgovN79V27mtZT TMHg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1710858959; x=1711463759; h=user-agent:in-reply-to:content-disposition:mime-version:references :mail-followup-to:message-id:subject:cc:to:from:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=luChDqVSAAc4fb7iffDdxPiZjioqHyEFcgfo6spQKkk=; b=JlGUjSdmjueu1+3gp8iXRj19mNW8FCNHSqB/ejm2hjdjK/BpbUJ6xFmDl+Sm4+IYYh 0ujCrL3913jQ0XuePOdsGI1gaELdqZhZ20/auKGppwKIAOLNWXLEIcqrl8lRsqwZNf0o cpLPscfZIOY/mtrSn6LlneVNHI1u7BAyutLLOmeeE1pysh+TnGJ7o5KSs4HGhLmQ/KRN /Pn4lP4/rEVk/zaNJtxI3xRljQC4GJ9wCxP3DA9lXDxWHNIMnkl2+YoIU9chLygKkBPl ExqNkUnpken6ReaBeszX/ut0+cDvdDOpXgF+UYXnbJn5oVIBjc41IRS4R3RN2/6xuPO2 hskg== X-Gm-Message-State: AOJu0YyQ4PZQPtAQHRkvupmlvYv30GFa4HtQoJ7+tnvNM/g1sLuAHths GceK1mdy6c5xyXP+xVQq0+y+aIFPVgpkFlmHcRZ9SoZkvPDbvzemys9YwtwS X-Google-Smtp-Source: AGHT+IECOqgdMgjifa1qd7xrYET/mAVWz8lY+KCuDP3JwACkl8wKNCM3spPGgYMNlkb+j+yHSxnfHw== X-Received: by 2002:a17:907:7294:b0:a46:b64e:58a1 with SMTP id dt20-20020a170907729400b00a46b64e58a1mr6578017ejc.25.1710858958983; Tue, 19 Mar 2024 07:35:58 -0700 (PDT) Received: from mariano ([188.210.239.9]) by smtp.gmail.com with ESMTPSA id h25-20020a17090634d900b00a46196a7faesm6123832ejb.57.2024.03.19.07.35.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 19 Mar 2024 07:35:58 -0700 (PDT) Received: by mariano (Postfix, from userid 1000) id BD180BFCDC; Tue, 19 Mar 2024 15:35:56 +0100 (CET) Date: Tue, 19 Mar 2024 15:35:56 +0100 From: Stefano Sabatini To: FFmpeg development discussions and patches Message-ID: Mail-Followup-To: FFmpeg development discussions and patches , Marth64 References: <20240317042940.2545620-1-marth64@proxyid.net> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20240317042940.2545620-1-marth64@proxyid.net> User-Agent: Mutt/2.1.4 (2021-12-11) Subject: Re: [FFmpeg-devel] [PATCH v4] avformat/rcwtdec: add RCWT Closed Captions demuxer 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 Cc: Marth64 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: On date Saturday 2024-03-16 23:29:41 -0500, Marth64 wrote: > Raw Captions With Time (RCWT) is a format native to ccextractor, a commonly > used open source tool for processing 608/708 Closed Captions (CC) sources. > RCWT can be used to archive the original CC bitstream. The muxer was added > in January 2024. In this commit, add the demuxer. > > One can now demux RCWT files for rendering in ccaption_dec or interoperate > with ccextractor (which produces RCWT). Using the muxer/demuxer combination, > the CC bits can be kept for further processing or rendering with either tool. > This can be an effective approach to backup original CC presentations. > > Prior to this, the next best solution was FFmpeg's SCC muxer, but SCC itself > is not compatible with ccextractor (which is a de facto OSS CC processing tool) > and it is a proprietary format. > > Tests will follow. > > Signed-off-by: Marth64 > --- > libavformat/Makefile | 1 + > libavformat/allformats.c | 1 + > libavformat/rcwtdec.c | 153 +++++++++++++++++++++++++++++++++++++++ missing Changelog entry > 3 files changed, 155 insertions(+) > create mode 100644 libavformat/rcwtdec.c > > diff --git a/libavformat/Makefile b/libavformat/Makefile > index 94a949f555..a6de720d8c 100644 > --- a/libavformat/Makefile > +++ b/libavformat/Makefile > @@ -493,6 +493,7 @@ OBJS-$(CONFIG_QOA_DEMUXER) += qoadec.o > OBJS-$(CONFIG_R3D_DEMUXER) += r3d.o > OBJS-$(CONFIG_RAWVIDEO_DEMUXER) += rawvideodec.o > OBJS-$(CONFIG_RAWVIDEO_MUXER) += rawenc.o > +OBJS-$(CONFIG_RCWT_DEMUXER) += rcwtdec.o subtitles.o > OBJS-$(CONFIG_RCWT_MUXER) += rcwtenc.o subtitles.o > OBJS-$(CONFIG_REALTEXT_DEMUXER) += realtextdec.o subtitles.o > OBJS-$(CONFIG_REDSPARK_DEMUXER) += redspark.o > diff --git a/libavformat/allformats.c b/libavformat/allformats.c > index e15d0fa6d7..3140018f8d 100644 > --- a/libavformat/allformats.c > +++ b/libavformat/allformats.c > @@ -391,6 +391,7 @@ extern const FFInputFormat ff_qoa_demuxer; > extern const FFInputFormat ff_r3d_demuxer; > extern const FFInputFormat ff_rawvideo_demuxer; > extern const FFOutputFormat ff_rawvideo_muxer; > +extern const FFInputFormat ff_rcwt_demuxer; > extern const FFOutputFormat ff_rcwt_muxer; > extern const FFInputFormat ff_realtext_demuxer; > extern const FFInputFormat ff_redspark_demuxer; > diff --git a/libavformat/rcwtdec.c b/libavformat/rcwtdec.c > new file mode 100644 > index 0000000000..1fd35be41b > --- /dev/null > +++ b/libavformat/rcwtdec.c > @@ -0,0 +1,153 @@ > +/* > + * RCWT (Raw Captions With Time) demuxer > + * > + * This file is part of FFmpeg. > + * > + * FFmpeg is free software; you can redistribute it and/or > + * modify it under the terms of the GNU Lesser General Public > + * License as published by the Free Software Foundation; either > + * version 2.1 of the License, or (at your option) any later version. > + * > + * FFmpeg is distributed in the hope that it will be useful, > + * but WITHOUT ANY WARRANTY; without even the implied warranty of > + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU > + * Lesser General Public License for more details. > + * > + * You should have received a copy of the GNU Lesser General Public > + * License along with FFmpeg; if not, write to the Free Software > + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA > + */ > + > +/* > + * RCWT (Raw Captions With Time) is a format native to ccextractor, a commonly > + * used open source tool for processing 608/708 Closed Captions (CC) sources. > + * It can be used to archive the original, raw CC bitstream and to produce > + * a source file for later CC processing or conversion. As a result, > + * it also allows for interopability with ccextractor for processing CC data > + * extracted via ffmpeg. The format is simple to parse and can be used > + * to retain all lines and variants of CC. > + * > + * This demuxer implements the specification as of March 2024, which has > + * been stable and unchanged since April 2014. > + * > + * A free specification of RCWT can be found here: > + * @url{https://github.com/CCExtractor/ccextractor/blob/master/docs/BINARY_FILE_FORMAT.TXT} > + */ move part of this content to doc/demuxers.texi Also having some practical example might be useful. [...] LGTM otherwise, thanks. _______________________________________________ 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".