VideoHelp Forum




+ Reply to Thread
Results 1 to 6 of 6
  1. Hey guys, new to the forum here and I need to know how you encode .ass subtitles from an mkv to the PSP's mp4. I've tried AVIdemux but it keeps crashing on me no matter what. I already know how to extract the .ass subs using MKVExtractGUI but my problem is that it won't show the correct effects (subtitles on top/bottom on certain timestamps) in the playing mp4 file.

    Am I missing something here? Any help is much appreciated.
    Quote Quote  
  2. Try AviSynth TextSub filter. It should support .ass subtitles. If you use something like AvsPMod it has a preview.
    In the simplest case you might start with an .avs script like this

    LoadPlugin("path to vsfilter.dll")
    DirectShowSource("video.mp4")
    TextSub("subs.ass")

    and see how it looks on preview. Then you have to feed the script into an encoding program that accepts AviSynth scripts .avs as input to actually encode the video with hard subs.
    http://milesaheadsoftware.org/
    Fully enabled freeware for Windows PCs.
    Quote Quote  
  3. I use Handbrake and it works very well.

    First, be sure your .ASS file is already muxed into the MKV. Handbrake won't recognize the ASS/SSA subtitle file if it's a separate file. If your subtitle file is standalone, use MkvmergeGUI to mux it in before trying to convert in Handbrake.

    After you've opened the MKV, go to the Subtitles tab, click the ADD button, and in the Source field, select the subtitle you want to use. Since you're hardsubbing, you'll only be able to use one (if your MKV contains more than one subtitle file).

    Also check the other tabs to make sure your new file will be IAW your wishes, such as selecting the correct audio track. You probably won't want an English soundtrack with your English subtitles if your MKV contains more than one audio track.

    To the right of the Source field, check the Burn In box.

    Click Start, or add to the Queue if you are doing more than one. There is also a button in the top banner to create and view a sample Preview of the finished file before you actually run the conversion.

    If you are doing more than one, you'll have to set up each file separately and add to the queue, as Handbrake won't batch set-up, but will batch process once you've set up each file.

    The resultant .m4v (ie, .mp4) will have the subtitles hardcoded into the video, with the original .ASS characteristics, including positioning miscellaneous captions on the page.

    I believe some .ASS files have movement, such as horizontal scrolling of song lyrics. I've never had one of those to try, but since the other .ASS characteristics display as created, I'm guessing there's a good chance those movements may, as well.

    As a final 'bennie', Handbrake will convert a 10-bit MKV into 8-bit. Seems to do it automatically, so if you want to keep the 10-bit format, keep this in mind.

    If you simply want to convert a 10-bit MKV to 8-bit and retain the softsubs, in the Output Settings section, select MKV in the Container field and in the Subtitle tab check the 'Default' checkbox instead of the 'Burn In'.

    Hope this helps.
    Quote Quote  
  4. Originally Posted by Houghton View Post
    I use Handbrake and it works very well.

    First, be sure your .ASS file is already muxed into the MKV. Handbrake won't recognize the ASS/SSA subtitle file if it's a separate file. If your subtitle file is standalone, use MkvmergeGUI to mux it in before trying to convert in Handbrake.

    After you've opened the MKV, go to the Subtitles tab, click the ADD button, and in the Source field, select the subtitle you want to use. Since you're hardsubbing, you'll only be able to use one (if your MKV contains more than one subtitle file).

    Also check the other tabs to make sure your new file will be IAW your wishes, such as selecting the correct audio track. You probably won't want an English soundtrack with your English subtitles if your MKV contains more than one audio track.

    To the right of the Source field, check the Burn In box.

    Click Start, or add to the Queue if you are doing more than one. There is also a button in the top banner to create and view a sample Preview of the finished file before you actually run the conversion.

    If you are doing more than one, you'll have to set up each file separately and add to the queue, as Handbrake won't batch set-up, but will batch process once you've set up each file.

    The resultant .m4v (ie, .mp4) will have the subtitles hardcoded into the video, with the original .ASS characteristics, including positioning miscellaneous captions on the page.

    I believe some .ASS files have movement, such as horizontal scrolling of song lyrics. I've never had one of those to try, but since the other .ASS characteristics display as created, I'm guessing there's a good chance those movements may, as well.

    As a final 'bennie', Handbrake will convert a 10-bit MKV into 8-bit. Seems to do it automatically, so if you want to keep the 10-bit format, keep this in mind.

    If you simply want to convert a 10-bit MKV to 8-bit and retain the softsubs, in the Output Settings section, select MKV in the Container field and in the Subtitle tab check the 'Default' checkbox instead of the 'Burn In'.

    Hope this helps.
    Thanks for your reply. I've already been using handbrake for a while and I've found it to be the most convenient and it outputs great results if used with the correct preset. But the thing is that some of the complex effects in an SSA sub aren't correctly converted. I reencode anime and effects like zooming, scrolling, and movement aren't rendered correctly. Have you encountered this issue? The good thing is that it gets better with every nightly release so I'm hoping to see full functionality with SSA soon.
    I'm too original for a signature.
    Quote Quote  
  5. Member Budman1's Avatar
    Join Date
    Jul 2012
    Location
    NORTHWEST ILLINOIS, USA
    Search Comp PM
    Just a quick extra method if you are familiar with FFMPEG at all or for others that are and maybe need this. Find out where your subtitle is located:

    ffmpeg -i "C:\path\sample004.mkv"

    This will give you something like this:
    Stream #0:0(eng): Video: h264 (High), yuv420p, 1280x534, SAR 1:1 DAR 640:267 , 23.98 fps, 23.98 tbr, 1k tbn, 47.95 tbc (default)
    Stream #0:1(eng): Audio: dts (DTS), 48000 Hz, 5.1(side), fltp, 1536 kb/s (default)
    Stream #0:2(fre): Subtitle: ssa (default)
    Stream #0:3(eng): Subtitle: ssa
    Metadata:
    title : english full subtitles
    Stream #0:4(eng): Subtitle: ssa
    Metadata:
    title : english forced subtitles

    EXTRACT FIRST ENGLISH SUBTITLE(ASS 0:3):
    ffmpeg -threads 4 -i "C:\path\sample004.mkv" -vn -an -map 0:3 -c:0 ass -y "C:\<path here>\engishSubtitle.ass"

    ADD subtitle track TO THE MP4:
    ffmpeg -i "C:\<enter Path here>\sample004.mp4" -i "C:\<Enter path here>\EnglishSubtitle.ass" -c:v copy -c:a copy -c mov_text -map 0:0 -map 0:1 -map 1:0 -y out.mp4

    HARDCODE SUBTITLES INTO VIDEO MP4:
    ffmpeg -i "C:\<path here>\sample004_Timed_1.MP4" -vf "ass='C\:\\Users\\Bud\\Desktop\\englishSubtitle.as s'" -vcodec libx264 -crf 22 -r 25 -acodec mp3 -ar 44.1k -b:a 128k "C:\<path here>\sample004_subbed.MP4"

    Strings are all continuous and the single and double quotes are there for a reason. SMILEYS are 'colon s'
    Quote Quote  
  6. But the thing is that some of the complex effects in an SSA sub aren't correctly converted. I reencode anime and effects like zooming, scrolling, and movement aren't rendered correctly. Have you encountered this issue? The good thing is that it gets better with every nightly release so I'm hoping to see full functionality with SSA soon.
    That's normal unless you hardcode the subtitles.
    Why? Because mp4s supported subtitle formats (http://gpac.wp.mines-telecom.fr/mp4box/mp4box-documentation/) are really restricted and often only ttxt is supported (and then only partially)

    So ttxt subtitles (see: http://gpac.wp.mines-telecom.fr/mp4box/ttxt-format-documentation/) normally is the default.
    QuickTime TeXML (see: http://www.qtc.jp/3GPP/Specs/26245-900.pdf) has/had lot of security implications, which is why it's also not that well supported.
    MP4Box also supports srt subtitles, but they are converted to ttxt.

    -> only way to preserve subtitle animations&co in mp4 would be to hardcode the subtitles.
    users currently on my ignore list: deadrats, Stears555, marcorocchini
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!