[FFmpeg-devel] [PATCH] dvbsub fix transcoding

anshul anshul.ffmpeg at gmail.com
Thu May 22 13:53:42 CEST 2014


On 05/22/2014 02:56 PM, Carl Eugen Hoyos wrote:
> Anshul Maheshwari <anshul.ffmpeg <at> gmail.com> writes:
>
> /* Note: DVB subtitle need one packet to draw them and one other
>>          packet to clear them */
>>       /* XXX: signal it in the codec context ? */
>>       if (enc->codec_id == AV_CODEC_ID_DVB_SUBTITLE)
>> -        nb = 2;
>> +        nb = 1;
> I tested your patch with the first sample from
> ticket #2024 (Starship_Troopers.vob) and as far
> as I can tell, it breaks the output. Does it work
> for you?
>
> Carl Eugen
>
> _______________________________________________
>

I did not remove the repeated code, because that will also require some 
re-indentation,
i was planning to make cosmetic changes later(next-patch). when people 
don't have/find
any problem with this patch.
according comments specified, i thought there is some code required to 
be done in dvbsubenc.
but cant say till i test some failing sample with this patch.

Yes,its work for me for 1st Video also, following is uncut console 
output. (while converting 1st video)
ffmpeg version N-63367-g22f8da0 Copyright (c) 2000-2014 the FFmpeg 
developers
   built on May 22 2014 12:02:15 with gcc 4.7 (SUSE Linux)
   configuration:
   libavutil      52. 86.100 / 52. 86.100
   libavcodec     55. 63.100 / 55. 63.100
   libavformat    55. 40.100 / 55. 40.100
   libavdevice    55. 13.101 / 55. 13.101
   libavfilter     4.  5.100 /  4.  5.100
   libswscale      2.  6.100 /  2.  6.100
   libswresample   0. 19.100 /  0. 19.100
Input #0, mpeg, from '/home/anshul/test_videos/Starship_Troopers.vob':
   Duration: 00:00:51.28, start: 1986.626100, bitrate: 4620 kb/s
     Stream #0:0[0x1e0]: Video: mpeg2video (Main), yuv420p(tv), 720x480 
[SAR 32:27 DAR 16:9], max. 9800 kb/s, 29.97 fps, 59.94 tbr, 90k tbn, 
59.94 tbc
     Stream #0:1[0x83]: Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s
     Stream #0:2[0x82]: Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s
     Stream #0:3[0x80]: Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s
     Stream #0:4[0x81]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 384 kb/s
     Stream #0:5[0x20]: Subtitle: dvd_subtitle
     Stream #0:6[0x22]: Subtitle: dvd_subtitle
File '/home/anshul/test_videos/test.ts' already exists. Overwrite ? [y/N] y
Output #0, mpegts, to '/home/anshul/test_videos/test.ts':
   Metadata:
     encoder         : Lavf55.40.100
     Stream #0:0: Video: mpeg2video, yuv420p, 720x480 [SAR 32:27 DAR 
16:9], q=2-31, 200 kb/s, 29.97 fps, 90k tbn, 29.97 tbc
     Metadata:
       encoder         : Lavc55.63.100 mpeg2video
     Stream #0:1: Audio: mp2, 48000 Hz, stereo, s16, 384 kb/s
     Metadata:
       encoder         : Lavc55.63.100 mp2
     Stream #0:2: Subtitle: dvb_subtitle (dvbsub)
     Metadata:
       encoder         : Lavc55.63.100 dvbsub
Stream mapping:
   Stream #0:0 -> #0:0 (mpeg2video -> mpeg2video)
   Stream #0:4 -> #0:1 (ac3 -> mp2)
   Stream #0:5 -> #0:2 (dvdsub -> dvbsub)
Press [q] to stop, [?] for help
[ac3 @ 0xaf1a940] frame sync error
Error while decoding stream #0:4: Invalid data found when processing input
[mpegts @ 0xae24b00] Non-monotonous DTS in output stream 0:1; previous: 
4804, current: 4084; changing to 4805. This may result in incorrect 
timestamps in the output file.
[mpeg @ 0xae228a0] New subtitle stream 0:7 at pos:8497166 and 
DTS:1999.51skbits/s dup=40 drop=0
[mpeg2video @ 0xae23460] ac-tex damaged at 3 27=00:00:43.60 
bitrate=1030.8kbits/s dup=261 drop=0
[mpeg2video @ 0xae23460] Warning MVs not available
[mpeg2video @ 0xae23460] concealing 135 DC, 135 AC, 135 MV errors in I frame
[ac3 @ 0xaf1a940] incomplete frame
frame= 1538 fps=439 q=31.0 Lsize=    6424kB time=00:00:51.28 
bitrate=1026.1kbits/s dup=309 drop=0
video:3251kB audio:2401kB subtitle:25kB other streams:0kB global 
headers:0kB muxing overhead: 13.162473%


thanks for reporting.

-Anshul




More information about the ffmpeg-devel mailing list