Open nestingBiscuit opened 5 months ago
Hi, it seems like your issue report has the following item(s) that need to be addressed:
This is an automated message, currently under testing. Please file an issue here if you encounter any problems.
I did file using the template, but I may have made an edit that triggered the bot :)
Please describe your bug
I have an older Samsung TV and it does not allow me to select UTF-8 as the subtitle encoding. It only has ISO-8859-X encodings to choose from.
Since Jellyfin always converts subtitle files to UTF-8, the decoding on the TV gets jumbled for special characters like 'é'. (See the images below)
After extensive testing, I have found that the TV does decode UTF-8 with BOM correctly.
It would be preferable if I were able to set the text encoding in the DLNA profile, but I do not have the expertise to tackle such a change. I have suggested it as a feature.
I was able to fix the issue by changing the subtitle encoding in:
https://github.com/jellyfin/jellyfin/blob/31aa44d23d12b5dbb5f9a131242cc82c9ef98f24/MediaBrowser.MediaEncoding/Subtitles/SubtitleEncoder.cs#L186
to UTF-8 with BOM:
I have tested this change with the few DLNA devices I own and they all show subtitles as expected. (Including the old Samsung TV)
I would be happy to make a pull request if this fix is deemed appropriate.
Reproduction Steps
Play a video with an external subtitle file that includes special characters, on a device that does not support UTF-8. I used this srt to test..
Jellyfin Version
10.9.0
if other:
10.9.6
Environment
Jellyfin logs
FFmpeg logs
No response
Please attach any browser or client logs here
No response
Please attach any screenshots here
UTF-8 error decoding: UTF-8-BOM correct decoding:
Code of Conduct