[FFmpeg-user] Copy DVB subtitles

Henk D. Schoneveld belcampo at zonnet.nl
Mon Dec 28 15:26:49 CET 2015


On 28 Dec 2015, at 14:16, Mitja Pirih <mitja at alternet.si> wrote:

> On 28. 12. 2015 12:30, Mitja Pirih wrote:
>> Hi,
>> 
>> I am trying to copy dvb subtitles from a multicast stream to a rtmp
>> stream (flv container). I am probably doing something wrong or maybe the
>> container does not accept dvb_subtitles format? I can't find anything
>> usable in docs.
>> 
>> I've got this:
>> Stream #0:0[0xc7]: Video: mpeg2video (Main) ([2][0][0][0] / 0x0002),
>> yuv420p(tv), 720x576 [SAR 64:45 DAR 16:9], max. 15000 kb/s, 25 fps, 25
>> tbr, 90k tbn, 50 tbc
>> Stream #0:1[0xc8]: Audio: mp2 ([3][0][0][0] / 0x0003), 48000 Hz, stereo,
>> s16p, 192 kb/s
>> Stream #0:2[0xcb](slv): Subtitle: dvb_subtitle ([6][0][0][0] / 0x0006)
>> Stream #0:3[0xcc](mac): Subtitle: dvb_subtitle ([6][0][0][0] / 0x0006)
>> 
>> I am trying to copy subtitles to a rtmp stream: -c:v copy -c:a copy
>> -scodec copy -f flv rtmp://localhost:1935/test/stream1
>> What I get is this error:
>> Could not write header for output file #0 (incorrect codec parameters
>> ?): Invalid data found when processing input
>> 
>> If I use something like this: -c:v copy -c:a copy -scodec copy output.ts
>> it works as expected. So I suppose what I am trying to do is not
>> compatible with flv. What options do I have?
>> 
>> 
>> Thanks.
> 
> It looks like I can "Burn-in" the subtitles and I actually managed to do
> that, following this guide:
> https://trac.ffmpeg.org/wiki/HowToBurnSubtitlesIntoVideo
> But, my question remains, is it possible to send subtitles in a rtmp stream?
FWIW if your subtitles are picture-based dvb_subtitles your options are limited to containers which accept these, mkv and ts and use a stream option which can work with one of them. HLS streaming and ts container is a option.
Another option is if the source stream also contains a text-based, teletext, subtitle stream that you can convert that to a srt stream which works with mkv mov mp4 and ts containers, I don’t know the flv container, but you might look up if that will enable what you want.
> 
> Thanks.
> _______________________________________________
> ffmpeg-user mailing list
> ffmpeg-user at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-user



More information about the ffmpeg-user mailing list