Unwanted transcoding of .MP4 files with {English Subtitles} in their names

For help and support with Universal Media Server
Forum rules
Please make sure you follow the Problem Reporting Guidelines before posting if you want a reply
Post Reply
UMSUSER2k
Posts: 2
Joined: Sat Aug 29, 2020 3:51 am

Unwanted transcoding of .MP4 files with {English Subtitles} in their names

Post by UMSUSER2k »

Hi,

On UMS 9.7.2, I have a load of (as far as I can tell) identically encoded videos, H264, MPEG-4 AVC, created with the same handbrake profile.

However, when browsing on some devices, some of the files show their names appended with "{English Subtitles}" or similar.

When I play these files on my chromecast via VLC for iOS, their names then get appended with "_transcoded_to_.ts"

It appears that UMS is forcibly and needlessly transcoding these files on the fly.

Is there any way I can stop this, or have I encoded my files in the wrong way?
Nadahar
Posts: 1990
Joined: Tue Jun 09, 2015 5:57 pm

Re: Unwanted transcoding of .MP4 files with {English Subtitles} in their names

Post by Nadahar »

Disclaimer: I haven't tested any of the later versions of UMS, so there could be bugs that I'm not familiar with.

That said, there are things you can do if this isn't caused by a bug. The situation is such that subtitles must be "rendered" on top of the video at some stage to be visible. This applies whether the subtitles are embedded in the file or in a separate file (external). Some renderers can handle some types of subtitles, while others can't. If your renderer configurations are correct, they should reflect this.

If a video file is supported by the renderer (format/codecs) and there are subtitles that should be displayed, what UMS does depends on whether or not the renderer can render the subtitles on top of the picture itself or not. If it can, UMS will send the subtitles in a separate stream if they are "external", or just send them with the file if they are embedded. This means that no transcoding is necessary. If the renderer can't handle the subtitles, UMS is forced to transcode the video even if the video itself is supported, so that the subtitles can be "burned in" so that they become a part of the video stream. In this case, the renderer has no idea that subtitles are involved at all, it just plays the video.

If the file format/codecs aren't supported, the file will be transcoded regardless of course, but it's quite common that transcoding must take place only to burn the subtitles in.

The things you can do is to make sure that the subtitles are configured correctly, so that subtitles are only shown when you want them to, and to make sure that the renderer configurations in question correctly reflects the capabilities of the renderers so that transcoding isn't done when the renderer could actually handle the subtitles.

You configure subtitles per audio language, so if you for example have English audio files with English subtitles, and don't want the subtitles to be displayed when that is the case, you must specify "eng:off" in the subtitles configuration. That will result in UMS not doing the transcoding when the audio and subtitles languages are both English. The only problem is that not all files are properly tagged with languages, and that most subtitles files doesn't support specifying the language at all. There are naming conventions, like "video.eng.srt" which will tell UMS that it's an English subtitles file, but you typically end up with situations where UMS can't figure out the language, and you end up with an "undefined" language. If that's your, you might have to define a rule for "und" as well.

The GUI for configuring the subtitles isn't very intuitive or self-explanatory, so you probably want to take a look here to make sense of it: https://github.com/UniversalMediaServer ... -Subtitles
UMSUSER2k
Posts: 2
Joined: Sat Aug 29, 2020 3:51 am

Re: Unwanted transcoding of .MP4 files with {English Subtitles} in their names

Post by UMSUSER2k »

That explanation helped enormously, so thank you! I have fixed the problem for most of the films. I need to do some tweaking for my non-English films, but 80% of my library works now :-)
Nadahar
Posts: 1990
Joined: Tue Jun 09, 2015 5:57 pm

Re: Unwanted transcoding of .MP4 files with {English Subtitles} in their names

Post by Nadahar »

Good to hear :)
Post Reply