#4754 closed defect (fixed)
dvbsub samples look very ugly
Reported by: | Carl Eugen Hoyos | Owned by: | |
---|---|---|---|
Priority: | normal | Component: | avcodec |
Version: | git-master | Keywords: | dvbsub |
Cc: | miguelapg | Blocked By: | |
Blocking: | Reproduced by developer: | no | |
Analyzed by developer: | no |
Description
http://samples.ffmpeg.org/ffmpeg-bugs/trac/ticket4752/
The subtitles in the sample from ticket #4752 look fine with vlc and probably readable with MPlayer but bad (and possibly unreadable) with current FFmpeg.
I also wonder if the warnings are correct or not.
$ ffmpeg -canvas_size pal -i dump_dvbsubtitles.mp4 -filter_complex [0:2]scale=hd1080,[0:0]overlay -qscale 2 out.avi ffmpeg version N-74271-g087c0a0 Copyright (c) 2000-2015 the FFmpeg developers built with gcc 4.7 (SUSE Linux) configuration: --enable-gpl libavutil 54. 30.100 / 54. 30.100 libavcodec 56. 57.100 / 56. 57.100 libavformat 56. 40.101 / 56. 40.101 libavdevice 56. 4.100 / 56. 4.100 libavfilter 5. 32.100 / 5. 32.100 libswscale 3. 1.101 / 3. 1.101 libswresample 1. 2.101 / 1. 2.101 libpostproc 53. 3.100 / 53. 3.100 [h264 @ 0x363c340] non-existing PPS 0 referenced Last message repeated 1 times [h264 @ 0x363c340] decode_slice_header error [h264 @ 0x363c340] no frame! [h264 @ 0x363c340] non-existing PPS 0 referenced Last message repeated 1 times [h264 @ 0x363c340] decode_slice_header error [h264 @ 0x363c340] no frame! [h264 @ 0x363c340] non-existing PPS 0 referenced Last message repeated 1 times [h264 @ 0x363c340] decode_slice_header error [h264 @ 0x363c340] no frame! [h264 @ 0x363c340] non-existing PPS 0 referenced Last message repeated 1 times [h264 @ 0x363c340] decode_slice_header error [h264 @ 0x363c340] no frame! [h264 @ 0x363c340] non-existing PPS 0 referenced Last message repeated 1 times [h264 @ 0x363c340] decode_slice_header error [h264 @ 0x363c340] no frame! [h264 @ 0x363c340] non-existing PPS 0 referenced Last message repeated 1 times [h264 @ 0x363c340] decode_slice_header error [h264 @ 0x363c340] no frame! [h264 @ 0x363c340] non-existing PPS 0 referenced Last message repeated 1 times [h264 @ 0x363c340] decode_slice_header error [h264 @ 0x363c340] no frame! [h264 @ 0x363c340] non-existing PPS 0 referenced Last message repeated 1 times [h264 @ 0x363c340] decode_slice_header error [h264 @ 0x363c340] no frame! [h264 @ 0x363c340] non-existing PPS 0 referenced Last message repeated 1 times [h264 @ 0x363c340] decode_slice_header error [h264 @ 0x363c340] no frame! [h264 @ 0x363c340] non-existing PPS 0 referenced Last message repeated 1 times [h264 @ 0x363c340] decode_slice_header error [h264 @ 0x363c340] no frame! [h264 @ 0x363c340] non-existing PPS 0 referenced Last message repeated 1 times [h264 @ 0x363c340] decode_slice_header error [h264 @ 0x363c340] no frame! [h264 @ 0x363c340] non-existing PPS 0 referenced Last message repeated 1 times [h264 @ 0x363c340] decode_slice_header error [h264 @ 0x363c340] no frame! [h264 @ 0x363c340] mmco: unref short failure Last message repeated 1 times [h264 @ 0x363c340] number of reference frames (0+4) exceeds max (3; probably corrupt input), discarding one [NULL @ 0x363e500] start time for stream 3 is not set in estimate_timings_from_pts [mpegts @ 0x3638360] PES packet size mismatch Input #0, mpegts, from 'dump_dvbsubtitles.mp4': Duration: 00:01:05.45, start: 57364.369689, bitrate: 6849 kb/s Program 1163 Stream #0:0[0xcb]: Video: h264 (High) ([27][0][0][0] / 0x001B), yuv420p(tv, bt709), 1920x1080 [SAR 1:1 DAR 16:9], 25 fps, 50 tbr, 90k tbn, 50 tbc Stream #0:1[0x193](eng): Audio: ac3 ([6][0][0][0] / 0x0006), 48000 Hz, 5.1(side), fltp, 448 kb/s Stream #0:2[0x25b](ara): Subtitle: dvb_subtitle ([6][0][0][0] / 0x0006) Stream #0:3[0x265](eng): Subtitle: dvb_subtitle ([6][0][0][0] / 0x0006) Please use -q:a or -q:v, -qscale is ambiguous Output #0, avi, to 'out.avi': Metadata: ISFT : Lavf56.40.101 Stream #0:0: Video: mpeg4 (FMP4 / 0x34504D46), yuv420p, 1920x1080 [SAR 1:1 DAR 16:9], q=2-31, 200 kb/s, 25 fps, 25 tbn, 25 tbc (default) Metadata: encoder : Lavc56.57.100 mpeg4 Stream #0:1(eng): Audio: ac3 ([0] [0][0] / 0x2000), 48000 Hz, 5.1(side), fltp, 448 kb/s Metadata: encoder : Lavc56.57.100 ac3 Stream mapping: Stream #0:0 (h264) -> overlay:main (graph 0) Stream #0:2 (dvbsub) -> scale (graph 0) overlay (graph 0) -> Stream #0:0 (mpeg4) Stream #0:1 -> #0:1 (ac3 (native) -> ac3 (native)) Press [q] to stop, [?] for help [h264 @ 0x4714f60] reference picture missing during reorder [h264 @ 0x4714f60] Missing reference picture, default is 2147483647 [h264 @ 0x475c6e0] mmco: unref short failure Last message repeated 1 times [h264 @ 0x475c6e0] number of reference frames (0+4) exceeds max (3; probably corrupt input), discarding one [h264 @ 0x475c6e0] reference picture missing during reorder [h264 @ 0x475c6e0] Missing reference picture, default is 65496 [dvbsub @ 0x363fba0] Invalid clut depth 0x0! Last message repeated 1 times [dvbsub @ 0x363fba0] Invalid clut depth 0x0! [dvbsub @ 0x363fba0] Invalid clut depth 0x0! [dvbsub @ 0x363fba0] Invalid clut depth 0x0! [dvbsub @ 0x363fba0] Invalid clut depth 0x0! Last message repeated 1 times [dvbsub @ 0x363fba0] Invalid clut depth 0x0! [dvbsub @ 0x363fba0] Invalid clut depth 0x0! Last message repeated 1 times [dvbsub @ 0x363fba0] Invalid clut depth 0x0! Last message repeated 1 times [dvbsub @ 0x363fba0] Invalid clut depth 0x0! [dvbsub @ 0x363fba0] Invalid clut depth 0x0! Last message repeated 1 times [dvbsub @ 0x363fba0] Invalid clut depth 0x0! [dvbsub @ 0x363fba0] Invalid clut depth 0x0! [dvbsub @ 0x363fba0] Invalid clut depth 0x0! [dvbsub @ 0x363fba0] Invalid clut depth 0x0! Last message repeated 1 times [dvbsub @ 0x363fba0] Invalid clut depth 0x0! [dvbsub @ 0x363fba0] Invalid clut depth 0x0! Last message repeated 1 times [dvbsub @ 0x363fba0] Invalid clut depth 0x0! [dvbsub @ 0x363fba0] Invalid clut depth 0x0! Last message repeated 1 times [dvbsub @ 0x363fba0] Invalid clut depth 0x0! [dvbsub @ 0x363fba0] Invalid clut depth 0x0! Last message repeated 1 times [dvbsub @ 0x363fba0] Invalid clut depth 0x0! [dvbsub @ 0x363fba0] Invalid clut depth 0x0! Last message repeated 1 times [dvbsub @ 0x363fba0] Invalid clut depth 0x0! [dvbsub @ 0x363fba0] Invalid clut depth 0x0! [dvbsub @ 0x363fba0] Invalid clut depth 0x0! [dvbsub @ 0x363fba0] Invalid clut depth 0x0! Last message repeated 1 times [dvbsub @ 0x363fba0] Invalid clut depth 0x0! Last message repeated 1 times [dvbsub @ 0x363fba0] Invalid clut depth 0x0! [dvbsub @ 0x363fba0] Invalid clut depth 0x0! Last message repeated 1 times [dvbsub @ 0x363fba0] Invalid clut depth 0x0! [mpegts @ 0x3638360] PES packet size mismatche=00:01:03.84 bitrate=13478.4kbits/s [ac3 @ 0x363f540] incomplete frame [h264 @ 0x47eb5e0] error while decoding MB 84 66, bytestream -20 frame= 1602 fps= 53 q=2.0 Lsize= 106323kB time=00:01:05.36 bitrate=13326.1kbits/s video:102700kB audio:3526kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.090437%
Attachments (1)
Change History (9)
comment:1 by , 10 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
by , 10 years ago
Attachment: | dvb_subtitles.jpg added |
---|
follow-up: 4 comment:2 by , 10 years ago
Subtitles are positioned according to PAL dimensions by default, instead of placing them at bottom center as VLC or MPlayer do.
Seems this was added at http://git.videolan.org/?p=ffmpeg.git;a=commitdiff;h=1fc20af6af3ec31d0ee665557885b6c20c6d3686.
Why VLC drop subtitles in the usual place (bottom center), and even scale subtitles to fit video dimension, and ffmpeg doesn't do it?
I think that this feature is not well-implemented if ffmpeg is not following the standards of video industry, as ffmpeg is also a reference in the video world.
I have attached an screenshot to show how subtitles are placed using a common set of parameters (even recommended by ffmpeg guides) ...
-filter_complex '[0:v][0:s:0]overlay[vid]' -map '[vid]' -map 0:a
Regards,
Mapg
comment:3 by , 10 years ago
Unfortunately DVB Substitles do not scale too as you can see using for example ...
-filter_complex '[0:s:0]scale=1920:1080[a];[0:v][a]overlay[vid]' -map '[vid]' -map 0:a
There is another recent ticket about this issue at https://trac.ffmpeg.org/ticket/4744
As reminder, let me add that all this stuff is coming from ticket ... https://trac.ffmpeg.org/ticket/4752 so you can find there inputs and console outputs or a video file sample at http://samples.ffmpeg.org/ffmpeg-bugs/trac/ticket4752/
Thanks
Mapg
comment:4 by , 10 years ago
Cc: | added |
---|
Replying to miguelapg:
Why VLC drop subtitles in the usual place (bottom center), and even scale subtitles to fit video dimension, and ffmpeg doesn't do it?
You apparently forgot to send a patch...
follow-up: 8 comment:5 by , 10 years ago
I do not say that ffmpeg is bad, I just want to remark what others are doing.
I do not program in your language, so I would like to help but I cannot unfortunalely.
What else I can do but reporting the bug and send reminder what others are doing?
Taking in consideration what I told you, how can I help you?
Regards,
Mapg
comment:6 by , 10 years ago
if ffmpeg is not following the standards of video industry,
What standards? DVD subs are overlaid on the video frame. There are no "bottom" borders or anything.
To me it seems subtitle handling can be arbitrarily complicated, but not overlaying them over the video frame correctly doesn't sound like reasonable default behavior.
comment:7 by , 10 years ago
I understand that "ways and customs" also create standards. I never saw a subtitle in other area.
Feel free to count with me to help to fix this issue. I can be useful to debug this issue for example.
Best regards,
Mapg
comment:8 by , 10 years ago
Replying to miguelapg:
I do not say that ffmpeg is bad
That is not how I understood your question, I just tried to answer.
I just want to remark what others are doing.
That is sometimes useful but for a reported and reproducible issue, I don't think it makes much sense.
I do not program in your language, so I would like to help but I cannot unfortunalely.
What else I can do but reporting the bug and send reminder what others are doing?
A reminder for a non-trivial ticket that was opened a few days ago is rarely interpreted as friendly.
(And it appears to me as if I reported the issue.)
Taking in consideration what I told you, how can I help you?
If you cannot send a patch, you will have to wait until somebody else does.
If you have usage questions, please remember that there is a user-mailing list, usage questions are not welcome on this bug tracker, it has already enough traffic.
Fixed by Michael in e5774f28d15887d36da25ae1ef2f1b3d7a75f449