[Commited] [Core] SSA burn-in support

Archive of historical development discussions
Discussions / Development has moved to GitHub
Forum rules
*******************************
Please be aware we are now using GitHub for issue tracking and feature requests.
- This section of the forum is now closed to new topics.

*******************************
s2koi
Posts: 1
Joined: Tue Jan 04, 2011 4:35 am

Re: [Patch] [Core] SSA burn-in support

Post by s2koi »

build: 0.9.5
encode: anime mkv w/ ssa subs (burn-in checked) > m4v file using AppleTV 2 preset

First time posting on this board... hopefully I did everything correctly. So glad that the new release now supports ssa/ass subs!

Not sure if the issue is with the source file but when I first encoded and added the SSA subtitles without checking any settings, the subs and video was totally out of sync. So I decided to just re-encode and checking the "burn-in" setting for the SSA subtitle. Now the syncing issue was not present but some letters are misaligned or not displaying correctly (see attached pic). I did notice that it does appear correctly in some sequences but the majority of the encode showed this behavior...

Image

Code: Select all

HandBrake Activity Log for Session (Cleared): 2011-01-03 19:57:01 -0800

[19:57:01] hb_init: checking cpu count
[19:57:01] hb_init: starting libhb thread
[19:57:01] macgui: Handbrake Version: 0.9.5 x86_64 (2011010300)
[19:57:01] hb_init: checking cpu count
[19:57:01] hb_init: starting libhb thread
[19:57:01] hb_init: checking cpu count
[19:57:01] hb_init: starting libhb thread
[19:57:01] macgui: hbInstances path to this instance: /Applications/HandBrake.app
[19:57:01] macgui: hbInstance found instance pidnum:1518 at path: /Applications/HandBrake.app
[19:57:01] macgui: hbInstance MATCH FOUND, our pidnum is:1518
[19:57:01] macgui: Pid for this instance:1518
[19:57:01] macgui: HBQueueController : My Pidnum is 1518
[19:57:14] macgui: trying to open video_ts folder (parent directory chosen)
[19:57:14] macgui: Preview: Disabling HUD Controls
[19:57:14] macgui: Minimum length of title for scan: 900000
[19:57:14] hb_scan: path=/Volumes/handbrake/cross game - 001.mkv, title_index=0
libbluray/bdnav/index_parse.c:157: indx_parse(): error opening /Volumes/handbrake/cross game - 001.mkv/BDMV/index.bdmv
libbluray/bluray.c:960: nav_get_title_list(/Volumes/handbrake/cross game - 001.mkv) failed (0x102861200)
[19:57:14] bd: not a bd - trying as a stream/file instead
libdvdnav: Using dvdnav version 4.1.3
libdvdread: Using libdvdcss version 1.2.10 for DVD access
libdvdnav:DVDOpenFileUDF:UDFFindFile /VIDEO_TS/VIDEO_TS.IFO failed
libdvdnav:DVDOpenFileUDF:UDFFindFile /VIDEO_TS/VIDEO_TS.BUP failed
libdvdread: Can't open file VIDEO_TS.IFO.
libdvdnav: vm: failed to read VIDEO_TS.IFO
[19:57:14] dvd: not a dvd - trying as a stream/file instead
Input #0, matroska,webm, from '/Volumes/handbrake/cross game - 001.mkv':
  Duration: 00:23:49.99, start: 0.000000, bitrate: N/A
    Chapter #0.0: start 0.000000, end 57.257000
    Metadata:
      title           : Introduction
    Chapter #0.1: start 57.257000, end 146.913000
    Metadata:
      title           : Opening
    Chapter #0.2: start 146.913000, end 146.913000
    Metadata:
      title           : Part A
    Chapter #0.3: start 698.898000, end 1301.634000
    Metadata:
      title           : Part B
    Chapter #0.4: start 1301.634000, end 1399.899000
    Metadata:
      title           : Ending
    Chapter #0.5: start 1399.899000, end 1429.929000
    Metadata:
      title           : Next Episode Preview
    Stream #0.0(jpn): Video: h264, yuv420p, 960x540, PAR 1:1 DAR 16:9, 29.97 fps, 29.97 tbr, 1k tbn, 59.94 tbc
    Metadata:
      title           : Main Video
    Stream #0.1(jpn): Audio: aac, 48000 Hz, stereo, s16
    Metadata:
      title           : Main Audio
    Stream #0.2: Subtitle: [0][0][0][0] / 0x0000
    Stream #0.3: Attachment: [0][0][0][0] / 0x0000
    Metadata:
      filename        : A-OTF-FutoGoB101Pro-Bold.ttf
    Stream #0.4: Attachment: [0][0][0][0] / 0x0000
    Metadata:
      filename        : 20th Century MT Sm Bd.ttf
    Stream #0.5: Attachment: [0][0][0][0] / 0x0000
    Metadata:
      filename        : 20th Century MT Bold.ttf
[19:57:14] scan: decoding previews for title 1
[19:57:15] scan: 10 previews, 960x540, 29.970 fps, autocrop = 0/0/0/0, aspect 16:9, PAR 1:1
[19:57:15] scan: title (0) job->width:960, job->height:544
[19:57:15] libhb: scan thread found 1 valid title(s)
[19:57:15] macgui: showNewScan: This is a new source item scan
[19:57:15] macgui: Preview: Enabling HUD Controls
[19:59:00] macgui: Rip: Pending queue count is 0
[19:59:00] macgui: getNextPendingQueueIndex next pending encode index is:0
[19:59:00] macgui: scanning specifically for title: 1
[19:59:00] hb_scan: path=/Volumes/handbrake/cross game - 001.mkv, title_index=1
libbluray/bdnav/index_parse.c:157: indx_parse(): error opening /Volumes/handbrake/cross game - 001.mkv/BDMV/index.bdmv
libbluray/bluray.c:960: nav_get_title_list(/Volumes/handbrake/cross game - 001.mkv) failed (0x10226f800)
[19:59:00] bd: not a bd - trying as a stream/file instead
libdvdnav: Using dvdnav version 4.1.3
libdvdread: Using libdvdcss version 1.2.10 for DVD access
libdvdnav:DVDOpenFileUDF:UDFFindFile /VIDEO_TS/VIDEO_TS.IFO failed
libdvdnav:DVDOpenFileUDF:UDFFindFile /VIDEO_TS/VIDEO_TS.BUP failed
libdvdread: Can't open file VIDEO_TS.IFO.
libdvdnav: vm: failed to read VIDEO_TS.IFO
[19:59:00] dvd: not a dvd - trying as a stream/file instead
Input #0, matroska,webm, from '/Volumes/handbrake/cross game - 001.mkv':
  Duration: 00:23:49.99, start: 0.000000, bitrate: N/A
    Chapter #0.0: start 0.000000, end 57.257000
    Metadata:
      title           : Introduction
    Chapter #0.1: start 57.257000, end 146.913000
    Metadata:
      title           : Opening
    Chapter #0.2: start 146.913000, end 146.913000
    Metadata:
      title           : Part A
    Chapter #0.3: start 698.898000, end 1301.634000
    Metadata:
      title           : Part B
    Chapter #0.4: start 1301.634000, end 1399.899000
    Metadata:
      title           : Ending
    Chapter #0.5: start 1399.899000, end 1429.929000
    Metadata:
      title           : Next Episode Preview
    Stream #0.0(jpn): Video: h264, yuv420p, 960x540, PAR 1:1 DAR 16:9, 29.97 fps, 29.97 tbr, 1k tbn, 59.94 tbc
    Metadata:
      title           : Main Video
    Stream #0.1(jpn): Audio: aac, 48000 Hz, stereo, s16
    Metadata:
      title           : Main Audio
    Stream #0.2: Subtitle: [0][0][0][0] / 0x0000
    Stream #0.3: Attachment: [0][0][0][0] / 0x0000
    Metadata:
      filename        : A-OTF-FutoGoB101Pro-Bold.ttf
    Stream #0.4: Attachment: [0][0][0][0] / 0x0000
    Metadata:
      filename        : 20th Century MT Sm Bd.ttf
    Stream #0.5: Attachment: [0][0][0][0] / 0x0000
    Metadata:
      filename        : 20th Century MT Bold.ttf
[19:59:00] scan: decoding previews for title 1
[19:59:01] scan: 10 previews, 960x540, 29.970 fps, autocrop = 0/0/0/0, aspect 16:9, PAR 1:1
[19:59:01] scan: title (0) job->width:960, job->height:544
[19:59:01] libhb: scan thread found 1 valid title(s)
[19:59:01] macgui: ScanDone state received from fQueueEncodeLibhb
[19:59:01] macgui: Preset: AppleTV 2
[19:59:01] macgui: processNewQueueEncode number of passes expected is: 1
[19:59:01] macgui: Start / Stop set to chapters
[19:59:01] macgui: prepareJob exiting
[19:59:01] 1 job(s) to process
[19:59:01] starting job
[19:59:01] Multiple decodes of audio id 1, removing track 2
[19:59:01] sync: expecting 42885 video frames
[19:59:01] job configuration:
[19:59:01]  * source
[19:59:01]    + /Volumes/handbrake/cross game - 001.mkv
[19:59:01]    + title 1, chapter(s) 1 to 6
[19:59:01]    + container: matroska,webm
[19:59:01]  * destination
[19:59:01]    + /Volumes/handbrake/cross game - 001anbu.m4v
[19:59:01]    + container: MPEG-4 (.mp4 and .m4v)
[19:59:01]      + 64-bit formatting
[19:59:01]      + chapter markers
[19:59:01]  * video track
[19:59:01]    + decoder: h264
[19:59:01]    + frame rate: 29.970 fps -> peak rate limited to 29.970 fps
[19:59:01]    + loose anamorphic
[19:59:01]      + storage dimensions: 960 * 540 -> 944 * 528, crop 0/0/0/0, mod 16
[19:59:01]      + pixel aspect ratio: 176 / 177
[19:59:01]      + display dimensions: 938 * 528
[19:59:01]    + encoder: x264
[19:59:01]      + quality: 20.00 (RF)
[19:59:01]  * subtitle track 0, Unknown (id 2) Text [SSA] -> Render/Burn in
[19:59:01]  * audio track 0
[19:59:01]    + decoder: Japanese (AAC) (2.0 ch) (track 1, id 1)
[19:59:01]    + mixdown: Stereo
[19:59:01]    + encoder: ca_aac
[19:59:01]      + bitrate: 160 kbps, samplerate: 48000 Hz
[19:59:01] encx264: min-keyint: auto (29), keyint: 300
[19:59:01] encx264: encoding with stored aspect 176/177
[19:59:01] encx264: Encoding at constant RF 20.000000
x264 [info]: using SAR=176/177
x264 [info]: using cpu capabilities: MMX2 SSE2Fast SSSE3 FastShuffle SSE4.2
x264 [info]: profile High, level 3.1
Fontconfig error: Cannot load default config file
[19:59:01] [ass] No usable fontconfig configuration file found, using fallback.
Fontconfig error: Cannot load default config file
[19:59:01] reader: first SCR 0 id 0 DTS 0
[19:59:15] h264: "Opening" (2) at frame 1724 time 5153130
[19:59:15] [ass] fontconfig: Selected font is not the requested one: '20th Century MT Sm Bd' != 'FutoGoB101Pro-Bold'
[19:59:15] [ass] Glyph 0xFF08 not found, selecting one more font for (FutoGoB101Pro-Bold, 80, 0)
[19:59:15] [ass] Glyph 0x81 not found, selecting one more font for (FutoGoB101Pro-Bold, 80, 0)
[19:59:15] [ass] Glyph 0x300C not found, selecting one more font for (FutoGoB101Pro-Bold, 80, 0)
[19:59:15] [ass] Glyph 0x300D not found, selecting one more font for (FutoGoB101Pro-Bold, 80, 0)
[19:59:15] [ass] Glyph 0xFF09 not found, selecting one more font for (FutoGoB101Pro-Bold, 80, 0)
[19:59:31] [ass] Glyph 0x30FB not found, selecting one more font for (FutoGoB101Pro-Bold, 80, 0)
[19:59:31] [ass] Glyph 0x81 not found, selecting one more font for (FutoGoB101Pro-Bold, 80, 0)
[19:59:32] [ass] Glyph 0x300C not found, selecting one more font for (FutoGoB101Pro-Bold, 80, 0)
[19:59:32] [ass] Glyph 0x300D not found, selecting one more font for (FutoGoB101Pro-Bold, 80, 0)
[19:59:32] [ass] Glyph 0xFF0F not found, selecting one more font for (FutoGoB101Pro-Bold, 80, 0)
[19:59:32] [ass] Glyph 0xFF08 not found, selecting one more font for (FutoGoB101Pro-Bold, 80, 0)
[19:59:32] [ass] Glyph 0xFF09 not found, selecting one more font for (FutoGoB101Pro-Bold, 80, 0)
[19:59:47] h264: "Part B" (4) at frame 4413 time 13228200
[20:05:01] h264: "Ending" (5) at frame 39018 time 117147060
[20:05:31] h264: "Next Episode Preview" (6) at frame 41964 time 125993880
[20:05:40] reader: done. 1 scr changes
[20:05:41] work: average encoding speed for job is 107.265640 fps
[20:05:41] sync: got 42855 frames, 42885 expected
[20:05:41] h264-decoder done: 42855 frames, 0 decoder errors, 0 drops
[20:05:41] render: 42855 frames output, 0 dropped and 0 duped for CFR/PFR
[20:05:41] render: lost time: 0 (0 frames)
[20:05:41] render: gained time: 0 (0 frames) (0 not accounted for)
x264 [info]: frame I:376   Avg QP:14.82  size: 62255  PSNR Mean Y:49.89 U:53.41 V:53.45 Avg:50.71 Global:49.50
x264 [info]: frame P:14213 Avg QP:16.35  size:  7101  PSNR Mean Y:47.12 U:50.75 V:50.82 Avg:48.00 Global:47.16
x264 [info]: frame B:28266 Avg QP:21.33  size:   617  PSNR Mean Y:47.52 U:51.01 V:51.10 Avg:48.38 Global:47.68
x264 [info]: consecutive B-frames:  8.6%  6.2%  5.9% 79.4%
x264 [info]: mb I  I16..4: 18.5% 44.5% 37.0%
x264 [info]: mb P  I16..4:  3.0%  2.9%  1.4%  P16..4: 23.3%  7.6%  5.5%  0.0%  0.0%    skip:56.3%
x264 [info]: mb B  I16..4:  0.0%  0.0%  0.0%  B16..8: 16.0%  0.7%  0.2%  direct: 0.5%  skip:82.6%  L0:40.3% L1:56.8% BI: 2.9%
x264 [info]: 8x8 transform intra:41.2% inter:68.1%
x264 [info]: coded y,uvDC,uvAC intra: 47.3% 62.2% 39.4% inter: 4.9% 7.2% 0.9%
x264 [info]: i16 v,h,dc,p: 64% 20%  6% 10%
x264 [info]: i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 16% 20% 32%  4%  5%  5%  7%  4%  6%
x264 [info]: i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 25% 19% 19%  6%  7%  7%  6%  6%  5%
x264 [info]: i8c dc,h,v,p: 55% 22% 18%  5%
x264 [info]: Weighted P-Frames: Y:4.2% UV:2.8%
x264 [info]: ref P L0: 68.5%  7.8% 16.6%  7.1%  0.1%
x264 [info]: ref B L0: 85.4% 11.9%  2.6%
x264 [info]: ref B L1: 92.7%  7.3%
x264 [info]: SSIM Mean Y:0.9940652 (22.266db)
x264 [info]: PSNR Mean Y:47.406 U:50.946 V:51.026 Avg:48.270 Global:47.515 kb/s:793.13
[20:05:41] aac-decoder done: 0 frames, 0 decoder errors, 0 drops
[20:05:42] mux: track 0, 42855 frames, 141748256 bytes, 793.00 kbps, fifo 8
[20:05:42] mux: track 1, 67032 frames, 29417828 bytes, 164.58 kbps, fifo 512
[20:05:42] libhb: work result = 0
[20:05:42] macgui: incrementQueueItemDone there are no more pending encodes
davidfstr
Enlightened
Posts: 149
Joined: Sun Apr 12, 2009 7:41 pm

Re: [Patch] [Core] SSA burn-in support

Post by davidfstr »

s2koi wrote:some letters are misaligned or not displaying correctly (see attached pic). I did notice that it does appear correctly in some sequences but the majority of the encode showed this behavior...
This is a known issue: http://trac.handbrake.fr/ticket/136

Thanks for reporting another example.
davidfstr
Enlightened
Posts: 149
Joined: Sun Apr 12, 2009 7:41 pm

Re: [Patch] [Core] SSA burn-in support

Post by davidfstr »

Ho boy... Now with 0.9.5 out the door, there'll be a flood of people banging on the new SSA support.

For new users that want to report SSA issues, please check the Trac to see whether the problem you are seeing is already known. All SSA-related tickets are prefixed with "SSA:"
TheRealWolf
Posts: 4
Joined: Sun Feb 20, 2011 4:07 pm

Re: [Commited] [Core] SSA burn-in support

Post by TheRealWolf »

Just wondering if SSA/ASS subtitle burn in will ever be fixed. The state it's in now is unusable.

The subs get out of sync and overlap especially top left corner they become unreadable.
User avatar
s55
HandBrake Team
Posts: 10350
Joined: Sun Dec 24, 2006 1:05 pm

Re: [Commited] [Core] SSA burn-in support

Post by s55 »

You could help out by providing a log, and a short sample that re-produces this.

If David is still around, hopefully he'll find time to look at it. If not, then likely someone from the community will need to submit a patch.
TheRealWolf
Posts: 4
Joined: Sun Feb 20, 2011 4:07 pm

Re: [Commited] [Core] SSA burn-in support

Post by TheRealWolf »

All issues have already been reported and are on the trac.

If you like i can provide additional evidence os the issues.

Don't want to sound harsh all the work done is appreciate though this feature shouldn't of made it into the final stable build it just doesn't work well enough to use.
User avatar
s55
HandBrake Team
Posts: 10350
Joined: Sun Dec 24, 2006 1:05 pm

Re: [Commited] [Core] SSA burn-in support

Post by s55 »

Don't want to sound harsh all the work done is appreciate though this feature shouldn't of made it into the final stable build it just doesn't work well enough to use.
HandBrake is an open source project run by a few volunteers in their free time. There is no dedicated testing team, fix team etc. IF we wait for all bugs to be fixed, it would never get Commited along with the majority of other features. IF it doesn't get Commited, then we won't know about the bugs and no-one can volunteer to improve it.
It works well enough for many for it to be useful.
Deleted User 11865

Re: [Commited] [Core] SSA burn-in support

Post by Deleted User 11865 »

Not to mention the fact that if it doesn't work for you, you can simply not use it. It doesn't break any existing functionality.
davidfstr
Enlightened
Posts: 149
Joined: Sun Apr 12, 2009 7:41 pm

Re: [Commited] [Core] SSA burn-in support

Post by davidfstr »

In case anyone is wondering, I'm still alive. I am, however, highly distracted.

Signed myself up to do an iPhone project for a client on top of my full-time job, and there's not much time left on the side for HandBrake. Probably won't see much out of me for several months. :(
TheRealWolf
Posts: 4
Joined: Sun Feb 20, 2011 4:07 pm

Re: [Commited] [Core] SSA burn-in support

Post by TheRealWolf »

Thats disappointing. Good luck with everything and hope to see you back soon.
jamiemlaw
Veteran User
Posts: 536
Joined: Thu Sep 17, 2009 4:52 pm

Re: [Commited] [Core] SSA burn-in support

Post by jamiemlaw »

davidfstr wrote:Signed myself up to do an iPhone project for a client
Please be iOS HandBrake, please be iOS HandBrake. :-)
TedJ
Veteran User
Posts: 5388
Joined: Wed Feb 20, 2008 11:25 pm

Re: [Commited] [Core] SSA burn-in support

Post by TedJ »

jamiemlaw wrote:
davidfstr wrote:Signed myself up to do an iPhone project for a client
Please be iOS HandBrake, please be iOS HandBrake. :-)
And steal cycles from my Folding@Phone client? Madness! :P
johan_lunds
Posts: 4
Joined: Wed Mar 09, 2011 10:25 am

Re: [Commited] [Core] SSA burn-in support

Post by johan_lunds »

Thought I'd post some material that perhaps will be of help for future work regarding SSA burn-in support: http://samples.mplayerhq.hu/Matroska/subtitles/

Sorry if it's old news.
sneaker
Posts: 7
Joined: Sat Apr 09, 2011 9:31 pm

Re: [Commited] [Core] SSA burn-in support

Post by sneaker »

I'm also experiencing problems with subtitles:

The sample I used for this test:
http://www.mediafire.com/?hiamk6v76wdxry4

I burn in the subtitles.

1.) Subtitles are bleeding
Image

This is probably the issue already reported in the trac:
https://trac.handbrake.fr/ticket/132


2.) A wild question mark appears:
Image

Both issues are not present using VLC which also uses libass to my knowledge.
I'm on Windows and tried 0.9.5 stable and 3915 nightly.
Last edited by sneaker on Sun Apr 10, 2011 7:52 pm, edited 1 time in total.
davidfstr
Enlightened
Posts: 149
Joined: Sun Apr 12, 2009 7:41 pm

Re: [Commited] [Core] SSA burn-in support

Post by davidfstr »

Thanks sneaker,

I've added these samples to the Trac items most likely to be related:
* SSA: Strange shadowing on some descender-letters (j,p,q)
* SSA: Kanji sometimes renders as squares

Now I just need to find some time to fix them...
aoaaron
Posts: 6
Joined: Thu Apr 05, 2012 9:58 am

Re: [Commited] [Core] SSA burn-in support

Post by aoaaron »

Hey, sorry to be a bother but has a fix or anything been provided/found?
User avatar
JohnAStebbins
HandBrake Team
Posts: 5712
Joined: Sat Feb 09, 2008 7:21 pm

Re: [Commited] [Core] SSA burn-in support

Post by JohnAStebbins »

Hard to say. Rendering is performed by libass and freetype. Both have been updated since this thread was last active (1yr). I don't know if anyone has retested these samples.
aoaaron
Posts: 6
Joined: Thu Apr 05, 2012 9:58 am

Re: [Commited] [Core] SSA burn-in support

Post by aoaaron »

Well I've had these results today:


http://img88.imageshack.us/img88/3113/s ... 6at093.png
converted m4v

http://imageshack.us/photo/my-images/17 ... 6at093.png
original mkv


Annoying because other animes/fansub groups encode perfectly fine (different fonts).
Post Reply