Editing Subtitle update

General questions or discussion about HandBrake, Video and/or audio transcoding, trends etc.
Post Reply
skylinekiller
Posts: 28
Joined: Thu Jan 17, 2019 9:12 am

Editing Subtitle update

Post by skylinekiller »

Is it possible to change the default value of the subtitles when the "burn in" option is used? I want to sue the following settings from my .ssa files
Style: Default,Univers CE 45 Light,42,16777215,0,16777215,0,-1,0,2,1,2,20,20,20,0,0

I haven't found a way to edit it yet. Is it at least possible to select an .ssa file and use it to burn into the video? If this is on the "to-do" list, what sort of donation would make it a top priority :)



HandBrake version: Nightly 20190111215932-217e9bb-master (2019011201)


Operating system and version Windows 10 updated 1 Nov 2019
User avatar
s55
HandBrake Team
Posts: 10350
Joined: Sun Dec 24, 2006 1:05 pm

Re: Editing Subtitle update

Post by s55 »

You can burn in a .ssa subtitle if you want (Might need a nightly build. Don't recall if 1.2.2 had that). Should honour fonts/styles reasonably well.
skylinekiller
Posts: 28
Joined: Thu Jan 17, 2019 9:12 am

Re: Editing Subtitle update

Post by skylinekiller »

Unfortunately, the only option on the nightly build is "Import SRT" There is no way to import a .ssa file
User avatar
s55
HandBrake Team
Posts: 10350
Joined: Sun Dec 24, 2006 1:05 pm

Re: Editing Subtitle update

Post by s55 »

Then yes, you'd need to run a nightly build for that functionality.
Woodstock
Veteran User
Posts: 4614
Joined: Tue Aug 27, 2013 6:39 am

Re: Editing Subtitle update

Post by Woodstock »

And the current nightly only deals with embedded fonts if, well, they're embedded in the video file. Otherwise, it substitutes system fonts, which might not be what you want.
skylinekiller
Posts: 28
Joined: Thu Jan 17, 2019 9:12 am

Re: Editing Subtitle update

Post by skylinekiller »

I either want to be able to change the font type, size, shaddow, etc with the nightly build or be able to load a .ssa file
Woodstock
Veteran User
Posts: 4614
Joined: Tue Aug 27, 2013 6:39 am

Re: Editing Subtitle update

Post by Woodstock »

I do not know if the graphic user interfaces have been updated to include "ssa from a file", but the nightly build command line interface has these switches to enable it:

Code: Select all

     --ssa-file <string>   SubStationAlpha SSA filename(s), separated by
                           commas.
     --ssa-offset <string> Offset (in milliseconds) to apply to the SSA
                           file(s), separated by commas. If not specified,
                           zero is assumed. Offsets may be negative.
     --ssa-lang <string>   SSA track language as an ISO 639-2 code
                           (e.g. fre, eng, spa, dut, et cetera)
                           If not specified, then 'und' is used.
                           Separate by commas.
     --ssa-default[=number]
                           Flag the selected SSA as the default subtitle
                           to be displayed during playback.
                           Setting no default means no subtitle will be
                           automatically displayed. If 'number' is omitted,
                           the first SSA is the default.
                           'number' is a 1-based index into the 'ssa-file' list
     --ssa-burn[=number]   "Burn" the selected SSA subtitle into
                           the video track.
                           If 'number' is omitted, the first SSA is burned.
                           'number' is a 1-based index into the 'ssa-file' list
If you multiplex the SSA file into your source (assuming an MKV file), you can use the SSA in the GUI. If you need non-standard fonts, this is the only way to do it right now.
skylinekiller
Posts: 28
Joined: Thu Jan 17, 2019 9:12 am

Re: Editing Subtitle update

Post by skylinekiller »

most of my sources are .mkv and I convert to .mp4. So I would have to create the ssa, then mux it into the .mkv, then use a command line to enable it. Sounds stupid, but where and how do I input the command line? Di I copy all of the text above?

This process is taking away the luxury of the program's great click/encode feature. Feel like I'm back in the MeGUI/Vdub days
User avatar
s55
HandBrake Team
Posts: 10350
Joined: Sun Dec 24, 2006 1:05 pm

Re: Editing Subtitle update

Post by s55 »

The Nightly GUI supports importing standalone .ass/ssa files. There is no need to use the CLI.
skylinekiller
Posts: 28
Joined: Thu Jan 17, 2019 9:12 am

Re: Editing Subtitle update

Post by skylinekiller »

Where is that option? This is the latest build as of 5 minutes ago. It only allows me to import .srt As you can see, the folder as .ssa inside of it but HB doesn't see them.

Image

https://imgur.com/96wqlxW
User avatar
s55
HandBrake Team
Posts: 10350
Joined: Sun Dec 24, 2006 1:05 pm

Re: Editing Subtitle update

Post by s55 »

Your not running a nightly build. That's 1.2.2
HandBrake nightly installs separably.
skylinekiller
Posts: 28
Joined: Thu Jan 17, 2019 9:12 am

Re: Editing Subtitle update

Post by skylinekiller »

This is the build I tried it on
https://imgur.com/EcE6TnL
User avatar
s55
HandBrake Team
Posts: 10350
Joined: Sun Dec 24, 2006 1:05 pm

Re: Editing Subtitle update

Post by s55 »

That build is from January this year. Try the latest version https://handbrake.fr/nightly.php
skylinekiller
Posts: 28
Joined: Thu Jan 17, 2019 9:12 am

Re: Editing Subtitle update

Post by skylinekiller »

Thank you, that seemed to work. I am able to load the .ssa, but when I get an error immediately when I start to encode. https://imgur.com/xuElcuE

Code: Select all

HandBrake Nightly 20191026200335-a366356-master (2019102601)
OS: Microsoft Windows NT 10.0.18362.0
CPU: Intel(R) Core(TM) i7-3970X CPU @ 3.50GHz
Ram: 32706 MB, 
GPU Information:
  NVIDIA GeForce GTX 660 Ti - 25.21.14.1722
Screen: 1680x1050
Temp Dir: C:\Users\John\AppData\Local\Temp\
Install Dir: C:\Program Files\HandBrake Nightly
Data Dir: C:\Users\John\AppData\Roaming\HandBrake\Nightly

-------------------------------------------


# Starting Encode ...

[05:44:20] base preset: Movies 1280p 5.1 AC3
[17:44:20] hb_init: starting libhb thread
[17:44:20] Starting work at: Wed Nov 06 17:44:20 2019
[17:44:20] 1 job(s) to process
[17:44:20] json job:
{
  "Audio": {
    "AudioList": [
      {
        "Bitrate": 448,
        "DRC": 0.0,
        "Encoder": "ac3",
        "Gain": 1.0,
        "Mixdown": 7,
        "NormalizeMixLevel": false,
        "Samplerate": 0,
        "Track": 0,
        "DitherMethod": 0
      }
    ],
    "CopyMask": [
      "copy:aac",
      "copy:ac3",
      "copy:dtshd",
      "copy:dts",
      "copy:eac3",
      "copy:flac",
      "copy:mp3",
      "copy:truehd"
    ],
    "FallbackEncoder": "ac3"
  },
  "Destination": {
    "ChapterList": [
      {
        "Name": "00:00:00.000"
      },
      {
        "Name": "00:09:46.419"
      },
      {
        "Name": "00:17:13.991"
      },
      {
        "Name": "00:37:43.887"
      },
      {
        "Name": "00:46:45.594"
      },
      {
        "Name": "00:48:07.259"
      },
      {
        "Name": "00:59:04.207"
      }
    ],
    "ChapterMarkers": true,
    "AlignAVStart": true,
    "File": "J:\\Star Trek Discovery s02e01-1.mp4",
    "Mp4Options": {
      "IpodAtom": false,
      "Mp4Optimize": false
    },
    "Mux": "mp4"
  },
  "Filters": {
    "FilterList": [
      {
        "ID": 4,
        "Settings": {
          "mode": "7"
        }
      },
      {
        "ID": 3,
        "Settings": {
          "block-height": "16",
          "block-thresh": "40",
          "block-width": "16",
          "filter-mode": "2",
          "mode": "3",
          "motion-thresh": "1",
          "spatial-metric": "2",
          "spatial-thresh": "1"
        }
      },
      {
        "ID": 12,
        "Settings": {
          "crop-bottom": "0",
          "crop-left": "0",
          "crop-right": "0",
          "crop-top": "0",
          "height": "536",
          "width": "1280"
        }
      },
      {
        "ID": 6,
        "Settings": {
          "mode": "2",
          "rate": "27000000/900000"
        }
      }
    ]
  },
  "PAR": {
    "Num": 1,
    "Den": 1
  },
  "Metadata": {},
  "SequenceID": 0,
  "Source": {
    "Angle": 1,
    "Range": {
      "Type": "chapter",
      "Start": 1,
      "End": 7
    },
    "Title": 1,
    "Path": "H:\\Need to Encode\\Star.Trek.Discovery.S02.720p.BluRay.x264-DEMAND\\Star Trek Discovery s02e01.mkv"
  },
  "Subtitle": {
    "Search": {
      "Burn": true,
      "Default": false,
      "Enable": true,
      "Forced": true
    },
    "SubtitleList": [
      {
        "Burn": false,
        "Default": false,
        "Forced": false,
        "ID": 0,
        "Offset": 0,
        "Track": -1,
        "Import": {
          "Codeset": "UTF-8",
          "Filename": "H:\\Need to Encode\\Star.Trek.Discovery.S02.720p.BluRay.x264-DEMAND\\1.ssa",
          "Language": "eng",
          "Format": "SSA"
        }
      }
    ]
  },
  "Video": {
    "Encoder": "x264",
    "Level": "4.1",
    "Bitrate": 2048,
    "TwoPass": true,
    "Turbo": true,
    "ColorMatrixCode": 0,
    "Options": "",
    "Preset": "fast",
    "Profile": "main",
    "QSV": {
      "Decode": false,
      "AsyncDepth": 0
    }
  }
}
[17:44:20] CPU: Intel(R) Core(TM) i7-3970X CPU @ 3.50GHz
[17:44:20]  - Intel microarchitecture Sandy Bridge
[17:44:20]  - logical processor count: 12
[17:44:20] hb_scan: path=H:\Need to Encode\Star.Trek.Discovery.S02.720p.BluRay.x264-DEMAND\Star Trek Discovery s02e01.mkv, title_index=1
udfread ERROR: ECMA 167 Volume Recognition failed
src/libbluray/disc/disc.c:323: failed opening UDF image H:\Need to Encode\Star.Trek.Discovery.S02.720p.BluRay.x264-DEMAND\Star Trek Discovery s02e01.mkv
src/libbluray/disc/disc.c:424: error opening file BDMV\index.bdmv
src/libbluray/disc/disc.c:424: error opening file BDMV\BACKUP\index.bdmv
src/libbluray/bluray.c:2585: nav_get_title_list(H:\Need to Encode\Star.Trek.Discovery.S02.720p.BluRay.x264-DEMAND\Star Trek Discovery s02e01.mkv\) failed
[17:44:20] bd: not a bd - trying as a stream/file instead
libdvdnav: Using dvdnav version 6.0.1
libdvdread: Encrypted DVD support unavailable.
libdvdread:DVDOpenFileUDF:UDFFindFile /VIDEO_TS/VIDEO_TS.IFO failed
libdvdread:DVDOpenFileUDF:UDFFindFile /VIDEO_TS/VIDEO_TS.BUP failed
libdvdread: Can't open file VIDEO_TS.IFO.
libdvdnav: vm: failed to read VIDEO_TS.IFO
[17:44:20] dvd: not a dvd - trying as a stream/file instead
Input #0, matroska,webm, from 'H:\Need to Encode\Star.Trek.Discovery.S02.720p.BluRay.x264-DEMAND\Star Trek Discovery s02e01.mkv':
  Metadata:
    encoder         : libebml v1.3.5 + libmatroska v1.4.8
    creation_time   : 2019-11-02T10:25:29.000000Z
  Duration: 01:00:06.31, start: 0.000000, bitrate: 6299 kb/s
    Chapter #0:0: start 0.000000, end 586.419000
    Metadata:
      title           : 00:00:00.000
    Chapter #0:1: start 586.419000, end 1033.991000
    Metadata:
      title           : 00:09:46.419
    Chapter #0:2: start 1033.991000, end 2263.887000
    Metadata:
      title           : 00:17:13.991
    Chapter #0:3: start 2263.887000, end 2805.594000
    Metadata:
      title           : 00:37:43.887
    Chapter #0:4: start 2805.594000, end 2887.259000
    Metadata:
      title           : 00:46:45.594
    Chapter #0:5: start 2887.259000, end 3544.207000
    Metadata:
      title           : 00:48:07.259
    Chapter #0:6: start 3544.207000, end 3606.311000
    Metadata:
      title           : 00:59:04.207
    Stream #0:0: Video: h264 (High), yuv420p(progressive), 1280x536 [SAR 1:1 DAR 160:67], 23.98 fps, 23.98 tbr, 1k tbn, 47.95 tbc (default)
    Metadata:
      BPS-eng         : 4788168
      DURATION-eng    : 01:00:06.311000000
      NUMBER_OF_FRAMES-eng: 86465
      NUMBER_OF_BYTES-eng: 2158453078
      _STATISTICS_WRITING_APP-eng: mkvmerge v22.0.0 ('At The End Of The World') 64-bit
      _STATISTICS_WRITING_DATE_UTC-eng: 2019-11-02 10:25:29
      _STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
    Stream #0:1(eng): Audio: dts (DTS), 48000 Hz, 5.1(side), fltp, 1536 kb/s (default)
    Metadata:
      BPS-eng         : 1508999
      DURATION-eng    : 01:00:05.323000000
      NUMBER_OF_FRAMES-eng: 337999
      NUMBER_OF_BYTES-eng: 680053988
      _STATISTICS_WRITING_APP-eng: mkvmerge v22.0.0 ('At The End Of The World') 64-bit
      _STATISTICS_WRITING_DATE_UTC-eng: 2019-11-02 10:25:29
      _STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
    Stream #0:2(eng): Subtitle: subrip (default) (forced)
    Metadata:
      title           : Forced
      BPS-eng         : 35
      DURATION-eng    : 00:00:01.116000000
      NUMBER_OF_FRAMES-eng: 1
      NUMBER_OF_BYTES-eng: 5
      _STATISTICS_WRITING_APP-eng: mkvmerge v22.0.0 ('At The End Of The World') 64-bit
      _STATISTICS_WRITING_DATE_UTC-eng: 2019-11-02 10:25:29
      _STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
[17:44:20] scan: decoding previews for title 1
[17:44:20] scan: audio 0x1: dca, rate=48000Hz, bitrate=1536000 English (DTS) (5.1 ch) (1536 kbps)
[17:44:21] scan: 10 previews, 1280x536, 23.976 fps, autocrop = 0/0/0/0, aspect 2.39:1, PAR 1:1
[17:44:21] libhb: scan thread found 1 valid title(s)
[17:44:21] Skipping subtitle scan.  No suitable subtitle tracks.
[17:44:21] Starting Task: Analysis Pass
[17:44:21] Skipping crop/scale filter
[17:44:21] job configuration:
[17:44:21]  * source
[17:44:21]    + H:\Need to Encode\Star.Trek.Discovery.S02.720p.BluRay.x264-DEMAND\Star Trek Discovery s02e01.mkv
[17:44:21]    + title 1, chapter(s) 1 to 7
[17:44:21]    + container: matroska,webm
[17:44:21]    + data rate: 6299 kbps
[17:44:21]  * destination
[17:44:21]    + J:\Star Trek Discovery s02e01-1.mp4
[17:44:21]    + container: MPEG-4 (libavformat)
[17:44:21]      + align initial A/V stream timestamps
[17:44:21]      + chapter markers
[17:44:21]  * video track
[17:44:21]    + decoder: h264
[17:44:21]    + filters
[17:44:21]      + Comb Detect (mode=3:spatial-metric=2:motion-thresh=1:spatial-thresh=1:filter-mode=2:block-thresh=40:block-width=16:block-height=16)
[17:44:21]      + Decomb (mode=39)
[17:44:21]      + Framerate Shaper (mode=2:rate=27000000/900000)
[17:44:21]        + frame rate: 23.976 fps -> peak rate limited to 30.000 fps
[17:44:21]    + Output geometry
[17:44:21]      + storage dimensions: 1280 x 536
[17:44:21]      + pixel aspect ratio: 1 : 1
[17:44:21]      + display dimensions: 1280 x 536
[17:44:21]    + encoder: H.264 (libx264)
[17:44:21]      + preset:  fast
[17:44:21]      + profile: main
[17:44:21]      + level:   4.1
[17:44:21]      + bitrate: 2048 kbps, pass: 1
[17:44:21]      + fast first pass
[17:44:21]      + options: ref=1:8x8dct=0:me=dia:trellis=0
[17:44:21]                 analyse=i4x4 (if originally enabled, else analyse=none)
[17:44:21]                 subq=2 (if originally greater than 2, else subq unchanged)
[17:44:21]      + color profile: 1-1-1
[17:44:21]  * subtitle track 1, English [SSA] (track 0, id 0xff000000, Text) -> Passthrough, offset: 0
[17:44:21]  * audio track 1
[17:44:21]    + decoder: English (DTS) (5.1 ch) (1536 kbps) (track 1, id 0x1)
[17:44:21]      + bitrate: 1536 kbps, samplerate: 48000 Hz
[17:44:21]    + mixdown: 5.1 Channels
[17:44:21]    + gain: 1dB
[17:44:21]    + dither: none
[17:44:21]    + encoder: AC3 (libavcodec)
[17:44:21]      + bitrate: 448 kbps, samplerate: 48000 Hz
Failure to initialise thread 'SSA Subtitle Decoder'
[17:44:21] comb detect: heavy 0 | light 0 | uncombed 0 | total 0
[17:44:21] decomb: deinterlaced 0 | blended 0 | unfiltered 0 | total 0
[17:44:21] vfr: 0 frames output, 0 dropped and 0 duped for CFR/PFR
[17:44:21] vfr: lost time: 0 (0 frames)
[17:44:21] vfr: gained time: 0 (0 frames) (0 not accounted for)
[17:44:21] dca-decoder done: 0 frames, 0 decoder errors
[17:44:21] Finished work at: Wed Nov 06 17:44:21 2019
[17:44:21] libhb: work result = 3

# Encode Completed ...

Woodstock
Veteran User
Posts: 4614
Joined: Tue Aug 27, 2013 6:39 am

Re: Editing Subtitle update

Post by Woodstock »

The first thing I would check is that the SSA file is actually using the character set UTF-8, as selected. It is uncommon for SSA files to NOT be in UTF-8 nowadays, but it can happen.
skylinekiller
Posts: 28
Joined: Thu Jan 17, 2019 9:12 am

Re: Editing Subtitle update

Post by skylinekiller »

It is UTF-8 but still getting errors
Deleted User 11865

Re: Editing Subtitle update

Post by Deleted User 11865 »

Can you post the file somewhere for us to look at (e.g. Dropbox)?
skylinekiller
Posts: 28
Joined: Thu Jan 17, 2019 9:12 am

Re: Editing Subtitle update

Post by skylinekiller »

I zipped two ssa and two srt. In order for SSRTtoSSA to convert, the text file needs to be Ansi, otherwise, it will kick an error for line 1.

Leave the useranme blank password= ssa
https://skylinekiller.cloud.seedboxes.c ... zq765yC4y4
Deleted User 11865

Re: Editing Subtitle update

Post by Deleted User 11865 »

Your SSA files are not valid, none of the tools I tried can make sense of it (ffmpeg, mkvmerge, Aegisub -- even Jubler opens it as a plain text file, not a subtitle). Whatever you're using to convert your subtitles is no good, try something else.
skylinekiller
Posts: 28
Joined: Thu Jan 17, 2019 9:12 am

Re: Editing Subtitle update

Post by skylinekiller »

What app do you recommend for SRT to SSA
skylinekiller
Posts: 28
Joined: Thu Jan 17, 2019 9:12 am

Re: Editing Subtitle update

Post by skylinekiller »

Interesting find. I have been using SRT to SSA Converter 1.0 for many years and never had issues with it encoding with VDUB. Anyways, I used Subitie Workshop. It's a few more steps then the SRT to SSA, but it's encoding now without an error. We will see if everything works well. For now, I guess this issue is resolved. Thank you. Will this feature be added to a stable build later?

Thank you for your patience and help.
Deleted User 11865

Re: Editing Subtitle update

Post by Deleted User 11865 »

Yes, nightly builds are just early Beta versions of the future "stable" HandBrake.
Post Reply