[FFmpeg-user] Burning DVD subtitles into video using overlay filter not working

Paul B Mahol onemda at gmail.com
Fri Aug 30 00:58:36 CEST 2013


On 8/29/13, Thierry Lelegard <thierry.lelegard at free.fr> wrote:
> Thanks for the troubleshooting steps.
>
> I tried all three steps and they all seem to indicate that the subtitles
> do exist and are not transparent. See below.
>
> As I mentioned in my original post, both vlc and mplayer correctly display
> the subtitles which are white with outline.
>
> If you are interested, the video file (20 seconds, 15 MB) is accessible at
> http://dl.free.fr/kHF1KGkZ7
>
> Le 29/08/2013 19:33, Nicolas George a ecrit :
>
>> Le duodi 12 fructidor, an CCXXI, Thierry Lelegard a ecrit :
>>> It seems the simplest possible command to do. Please don't comment on
>>> video
>>> quality, it is just a test to see if the subtitles are burnt into the
>>> video.
>>> The resulting video does not contain subtitles.
>> It should be working. I suggest three steps to understand how it fails:
>>
>> First, use -loglevel debug and look at the "palette:" lines: maybe the
>> subtitles are completely transparent.
>
> Got the following. See the full output at the end of the mail.
>
> [dvdsub @ 00000000021b74e0] palette: 0x000000 0xf0f0f0 0xcccccc 0x999999
> 0x3333fa 0x1111bb 0xfa3333 0xbb1111 0x33fa33 0x11bb11 0xfafa33 0xbbbb11
> 0xfa33fa 0xbb11bb 0x33fafa 0x11bbbb
>
> The subtitles are not transparent.
>
>> Second, add a showinfo filter after the subtitles input, something like
>> that:
>>
>>    [0:s]ashowinfo[s];[0:v][s]overlay
>>
>> That way, you can see if subtitles packets arrive.
>
> I guess you mean "showinfo", not "ashowinfo", this is not audio.
> Got the following. Again, see the full output at the end of the mail.
>
> [Parsed_showinfo_0 @ 0000000000351160] n:0 pts:0 pts_time:0 pos:0 fmt:bgra
> sar:0/0 s:1920x1080 i:P iskey:0 type:? checksum:504E28AB
> plane_checksum:[504E28AB]
> [Parsed_showinfo_0 @ 0000000000351160] n:1 pts:587 pts_time:0.587 pos:0
> fmt:bgra sar:0/0 s:1920x1080 i:P iskey:0 type:? checksum:504E28AB
> plane_checksum:[504E28AB]
> [Parsed_showinfo_0 @ 0000000000351160] n:2 pts:926 pts_time:0.926 pos:0
> fmt:bgra sar:0/0 s:1920x1080 i:P iskey:0 type:? checksum:504E28AB
> plane_checksum:[504E28AB]
> ....
>
> So, the packets are seen by the filter chain. I am not sure how to
> interpret
> some of those values.
>
>> Third, extract the subtitles track with mkvextract, and look at the
>> index,
>> especially the size, the palette, etc.
>
> $ mkvextract tracks gg.mkv 2:gg.sub
> Extracting track 2 with the CodecID 'S_VOBSUB' to the file 'gg.sub'.
> Container format: VobSubs
> Writing the VobSub index file 'gg.idx'.
> Progress: 100%
>
> The content of the index is:
>
> # VobSub index file, v7 (do not modify this line!)
> size: 1920x1080
> org: 0, 0
> scale: 100%, 100%
> alpha: 100%
> smooth: OFF
> fadein/out: 0, 0
> align: OFF at LEFT TOP
> time offset: 0
> forced subs: OFF
> palette: 000000, f0f0f0, cccccc, 999999, 3333fa, 1111bb, fa3333, bb1111,
> 33fa33, 11bb11, fafa33, bbbb11, fa33fa, bb11bb, 33fafa, 11bbbb
> custom colors: OFF, tridx: 1000, colors: 000000, 444444, 888888, cccccc
>

Well entries are really transparent.

[...]


More information about the ffmpeg-user mailing list