[FFmpeg-devel] [PATCH] libavcodec/htmlsubtitles: skip newline characters at the beginning of the subtitle

wm4 nfxjfg at googlemail.com
Tue Jun 20 11:07:54 EEST 2017


On Fri, 16 Jun 2017 23:40:32 +0300
Evgeny Shulgin <izaronplatz at gmail.com> wrote:

> > Anyway, I don't understand why this makes subtitle lines actually
> > disappear?  
> 
> Because SubRip format does not allow to have empty lines, that is:
> 
>    1. Subtitle text itself on one or more lines
>    2. A blank line containing no text, indicating the end of this subtitle
> 
> So, when we have '\n' at the start or two '\n'-s in a row, the code
> interrupts the recording of sub. But in this video we could get subtitles
> as "\r\n\r\n\r\nСкандинавия", and this video is played perfectly in VLC
> player like it's "Скандинавия". So we had to deal with it. Anyway, this
> .mkv was recorded successfully a couple of years ago:
> 
>   Metadata:
>     encoder         : libebml v1.3.0 + libmatroska v1.4.1
>     creation_time   : 2015-05-30T16:56:01.000000Z
> 
> _STATISTICS_WRITING_APP: mkvmerge v7.0.0 ('Where We Going') 32bit built on
> Jun  9 2014 15:08:34

I could understand if this was in the .srt parser, but this is just the
srt to ass converter. Does the latter really drop anything after the
first newline?

> 
> > Most of this should probably go into the commit message  
> 
> How can I edit the patch? Send the updated patch as attachment in the emal?
> I don't see how can I do it on the patchwork site. Thanks!

Just use -v2 and maybe --in-reply-to= with the message ID.


More information about the ffmpeg-devel mailing list