From: Stefano Sabatini <stefasab@gmail.com> To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org> Cc: Marth64 <marth64@proxyid.net> Subject: Re: [FFmpeg-devel] [PATCH v4] avformat/rcwtdec: add RCWT Closed Captions demuxer Date: Tue, 19 Mar 2024 15:35:56 +0100 Message-ID: <ZfmizLdI7hCHATD6@mariano> (raw) In-Reply-To: <20240317042940.2545620-1-marth64@proxyid.net> 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 <marth64@proxyid.net> > --- > 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".
next prev parent reply other threads:[~2024-03-19 14:36 UTC|newest] Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top 2024-03-12 5:59 [FFmpeg-devel] [PATCH v3 0/6] Closed Captions improvements (phase 1) Marth64 2024-03-12 6:00 ` [FFmpeg-devel] [PATCH v3 1/6] avcodec/mpeg12dec: extract only one type of CC substream Marth64 2024-03-12 11:00 ` Stefano Sabatini 2024-03-12 11:52 ` Andreas Rheinhardt 2024-03-28 9:29 ` Anton Khirnov 2024-03-28 15:41 ` Marth64 2024-03-12 6:00 ` [FFmpeg-devel] [PATCH v3 2/6] avcodec/ccaption_dec: don't print multiple \an and \pos tags Marth64 2024-03-12 13:49 ` Stefano Sabatini 2024-03-12 6:00 ` [FFmpeg-devel] [PATCH v3 3/6] avcodec/ccaption_dec: ignore leading non-breaking spaces Marth64 2024-03-12 13:50 ` Stefano Sabatini 2024-03-17 4:27 ` Marth64 2024-03-12 6:00 ` [FFmpeg-devel] [PATCH v3 4/6] avcodec/rcwtenc: canonize name and refresh documentation Marth64 2024-03-12 13:52 ` Stefano Sabatini 2024-03-12 6:00 ` [FFmpeg-devel] [PATCH v3 5/6] avformat/rcwtdec: add RCWT Closed Captions demuxer Marth64 2024-03-12 11:44 ` Andreas Rheinhardt 2024-03-12 14:12 ` Marth64 2024-03-17 4:29 ` [FFmpeg-devel] [PATCH v4] " Marth64 2024-03-18 20:12 ` Marth64 2024-03-19 14:35 ` Stefano Sabatini [this message] 2024-03-19 15:55 ` Marth64 2024-03-19 17:39 ` [FFmpeg-devel] [PATCH v5 1/4] " Marth64 2024-03-19 17:39 ` [FFmpeg-devel] [PATCH v5 2/4] avformat/rcwtenc: remove repeated documentation Marth64 2024-03-19 17:39 ` [FFmpeg-devel] [PATCH v5 3/4] doc/muxers: refresh and simplify RCWT muxer documentation Marth64 2024-03-19 17:39 ` [FFmpeg-devel] [PATCH v5 4/4] doc/indevs: update CC extraction example to use RCWT muxer Marth64 2024-03-20 14:13 ` Stefano Sabatini 2024-03-19 21:41 ` [FFmpeg-devel] [PATCH v5 1/4] avformat/rcwtdec: add RCWT Closed Captions demuxer Michael Niedermayer 2024-03-19 22:07 ` Marth64 2024-03-20 14:11 ` Stefano Sabatini 2024-03-12 6:00 ` [FFmpeg-devel] [PATCH v3 6/6] avformat/sccdec: remove unused bprint.h include Marth64 2024-03-12 13:53 ` Stefano Sabatini
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=ZfmizLdI7hCHATD6@mariano \ --to=stefasab@gmail.com \ --cc=ffmpeg-devel@ffmpeg.org \ --cc=marth64@proxyid.net \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel This inbox may be cloned and mirrored by anyone: git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \ ffmpegdev@gitmailbox.com public-inbox-index ffmpegdev Example config snippet for mirrors. AGPL code for this site: git clone https://public-inbox.org/public-inbox.git