[FFmpeg-devel] [PATCH] avformat: Add rtp_mpegtsraw (MPEG-TS RAW Stream output)

Michael Niedermayer michael at niedermayer.cc
Tue Jan 10 15:36:58 EET 2017


On Mon, Jan 09, 2017 at 02:59:37PM -0500, Andreas Håkon wrote:
> Hi,
> 
> This patch adds a new MUXER named "rtp_mpegtsraw". This new muxer works with
> the "mpegtsraw" input demuxer. The objective is enable direct bitstream
> input-output of MPEG-TS for RTP+FEC. Using the recent support for Pro-MPEG CoP
> FEC protocol, you can now use FFmpeg for streaming any UDP/RTP MPEG-TS stream.
> 
> Example:
> 
> ffmpeg -f mpegtsraw -i udp://239.8.8.8:12345 -map 0 -c copy -f rtp_mpegtsraw -fec prompeg=l=8:d=8 rtp://239.9.9.9:10000
> 
> In this example FFmpeg reads from the network one stream in UDP o RTP format
> from the multicast address 239.8.8.8:12345 and re-encapsulates it without
> remuxing to the multicast address 239.9.9.9 using RTP+FEC
> (ports 10000 & 10001 are for the base RTP, port 10002 are for "row" and 10004
> are for "column").
> 
> If you ever have had the need to do use FFmpeg in plain "bitstream" mode
> with MPEG-TS streams, you have luck: know you can!
> 
> Please comment,
> Andreas Håkon
> 
> 
> Signed-off-by: Andreas Håkon <andreas.hakon at protonmail.com>
> ---
> ffmpeg.c | 1 +
> libavformat/allformats.c | 1 +
> libavformat/mpegts.c | 2 +-
> libavformat/rtpenc.c | 6 ++++++
> libavformat/rtpenc_mpegts.c | 48 +++++++++++++++++++++++++++++++++++++++++++++
> 5 files changed, 57 insertions(+), 1 deletion(-)
> 
> diff --git a/ffmpeg.c b/ffmpeg.c
> index b85c314..838f4d2 100644
> --- a/ffmpeg.c
> +++ b/ffmpeg.c
> @@ -3228,6 +3228,7 @@ static int init_output_stream_encode(OutputStream *ost)
> }
> break;
> case AVMEDIA_TYPE_DATA:
> + av_log(NULL, AV_LOG_TRACE, "Using bitstream with codec %s\n", avcodec_get_name(enc_ctx->codec_id));
> break;
> default:
> abort();
> diff --git a/libavformat/allformats.c b/libavformat/allformats.c
> index 6a79b75..b58e178 100644

patch seems corrupted:

Applying: avformat: Add rtp_mpegtsraw (MPEG-TS RAW Stream output)
error: corrupt patch at line 14
error: could not build fake ancestor
Patch failed at 0001 avformat: Add rtp_mpegtsraw (MPEG-TS RAW Stream output)
The copy of the patch that failed is found in: .git/rebase-apply/patch
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".


[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

In fact, the RIAA has been known to suggest that students drop out
of college or go to community college in order to be able to afford
settlements. -- The RIAA
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20170110/1cdc61e7/attachment.sig>


More information about the ffmpeg-devel mailing list