Correct encoding for Subtitles

HandBrake for Mac support
Forum rules
An Activity Log is required for support requests. Please read How-to get an activity log? for details on how and why this should be provided.
Post Reply
miklos
Posts: 16
Joined: Thu Mar 30, 2017 5:13 pm

Correct encoding for Subtitles

Post by miklos »

Description of problem or question
I am attempting to add English subs to some foreign opera downloads and the results seem to produce incorrect characters after adding SRT subs as an imported external SRT. Everything appears on the screen correctly but the text is often jumbled with strange characters. Simple words like " what's " will appear with all manner of symbols where the apostrophe should be. Do I need to alter the default subtitle encoding to handle commas, etc? It is currently set at ISO-8859-1 - but am unsure what all these different encodings are used for, etc. Any advice. Cheers ;-)

HandBrake version
1.0.7 (2017040900)

Operating system and version
macOS High Sierra 10.13.3
User avatar
BradleyS
Moderator
Posts: 1860
Joined: Thu Aug 09, 2007 12:16 pm

Re: Correct encoding for Subtitles

Post by BradleyS »

Definitely sounds like an encoding issue, try UTF-8. Basically, the SRT format isn’t very well standardized and it could be anything.
miklos
Posts: 16
Joined: Thu Mar 30, 2017 5:13 pm

Re: Correct encoding for Subtitles

Post by miklos »

Thanks for that, BradleyS. Changing to UTF-8 seems have worked like magic. I did a test run by adding my own subs made up of the full lower & upper keyboard characters and everything came through as intended without any errors. I even checked out a few accented letters and they worked fine. Great stuff. I want to use UTF-8 each time in future - but Handbrake seems to default to the previous ISO-8859-1 instead. Is there a way to set up Handbrake to accept UTF-8 as the default? Cheers :-)
User avatar
BradleyS
Moderator
Posts: 1860
Joined: Thu Aug 09, 2007 12:16 pm

Re: Correct encoding for Subtitles

Post by BradleyS »

Currently we don't have a way to intelligently set the SRT character encoding, and it's not saved in a preset. So there is no easy way to change the default (unless you use the command line version and set it manually there). We could probably try to detect UTF-8 specifically down the road via the (often omitted) byte marker or other means, but this is low priority at the moment.

A lot of subs in the wild are UTF-8 these days because it is standardized for other technologies and can encode many languages. That said, a given .SRT file could be anything.

In any case, am glad to hear you got it working, even if it's a bit cumbersome.
robertogonzalez
New User
Posts: 1
Joined: Fri Aug 09, 2019 8:42 pm

Re: Correct encoding for Subtitles

Post by robertogonzalez »

Thank you, BradleyS! I was working on Spanish subtitles and ISO-8859 was misreading accented characters, initial question marks and the ñ. Switched to UTF-8 and it worked like a charm! :D
User avatar
BradleyS
Moderator
Posts: 1860
Joined: Thu Aug 09, 2007 12:16 pm

Re: Correct encoding for Subtitles

Post by BradleyS »

:)
flamingo07
Posts: 1
Joined: Fri Oct 30, 2020 6:45 pm

Re: Correct encoding for Subtitles

Post by flamingo07 »

Hey! i'm new here and don't know how to switch my spanish srt files to UTF-8 while on Mac ¿what can i do to encode correctly spanish subtitles?
Thanks.
Post Reply