diff options
| author | Luke Pulverenti <luke.pulverenti@gmail.com> | 2016-03-22 00:15:12 -0400 |
|---|---|---|
| committer | Luke Pulverenti <luke.pulverenti@gmail.com> | 2016-03-22 00:15:12 -0400 |
| commit | 49c678037a329f35de0ff09999b79cd8a1d4694d (patch) | |
| tree | 594e63f2abbe767be61b73e9af3c493e2d195ac4 | |
| parent | 7a014affb27b3e3d00680e39ce6b858f6d954ec6 (diff) | |
fix samsung dlna subtitles
| -rw-r--r-- | MediaBrowser.Dlna/Didl/DidlBuilder.cs | 20 | ||||
| -rw-r--r-- | MediaBrowser.MediaEncoding/Subtitles/SubtitleEncoder.cs | 2 |
2 files changed, 11 insertions, 11 deletions
diff --git a/MediaBrowser.Dlna/Didl/DidlBuilder.cs b/MediaBrowser.Dlna/Didl/DidlBuilder.cs index 91d1af8f4..e8e969a5f 100644 --- a/MediaBrowser.Dlna/Didl/DidlBuilder.cs +++ b/MediaBrowser.Dlna/Didl/DidlBuilder.cs @@ -188,15 +188,15 @@ namespace MediaBrowser.Dlna.Didl { var subtitleAdded = AddSubtitleElement(container, subtitle); - if (subtitleAdded && _profile.EnableSingleSubtitleLimit) - { - break; - } + if (subtitleAdded && _profile.EnableSingleSubtitleLimit) + { + break; + } } } } - private bool AddSubtitleElement(XmlElement container, SubtitleStreamInfo info) + private bool AddSubtitleElement(XmlElement container, SubtitleStreamInfo info) { var subtitleProfile = _profile.SubtitleProfiles .FirstOrDefault(i => string.Equals(info.Format, i.Format, StringComparison.OrdinalIgnoreCase) && i.Method == SubtitleDeliveryMethod.External); @@ -213,13 +213,13 @@ namespace MediaBrowser.Dlna.Didl // <sec:CaptionInfoEx sec:type="srt">http://192.168.1.3:9999/video.srt</sec:CaptionInfoEx> // <sec:CaptionInfo sec:type="srt">http://192.168.1.3:9999/video.srt</sec:CaptionInfo> - //var res = container.OwnerDocument.CreateElement("SEC", "CaptionInfoEx"); + var res = container.OwnerDocument.CreateElement("CaptionInfoEx", "sec"); - //res.InnerText = info.Url; + res.InnerText = info.Url; //// TODO: attribute needs SEC: - //res.SetAttribute("type", info.Format.ToLower()); - //container.AppendChild(res); + res.SetAttribute("type", "sec", info.Format.ToLower()); + container.AppendChild(res); } else if (string.Equals(subtitleMode, "smi", StringComparison.OrdinalIgnoreCase)) { @@ -243,7 +243,7 @@ namespace MediaBrowser.Dlna.Didl container.AppendChild(res); } - return true; + return true; } private void AddVideoResource(XmlElement container, IHasMediaSources video, string deviceId, Filter filter, string contentFeatures, StreamInfo streamInfo) diff --git a/MediaBrowser.MediaEncoding/Subtitles/SubtitleEncoder.cs b/MediaBrowser.MediaEncoding/Subtitles/SubtitleEncoder.cs index 882b2e1c2..cbe24bda8 100644 --- a/MediaBrowser.MediaEncoding/Subtitles/SubtitleEncoder.cs +++ b/MediaBrowser.MediaEncoding/Subtitles/SubtitleEncoder.cs @@ -604,7 +604,7 @@ namespace MediaBrowser.MediaEncoding.Subtitles process.StandardError.BaseStream.CopyToAsync(logFileStream); - var ranToCompletion = process.WaitForExit(120000); + var ranToCompletion = process.WaitForExit(300000); if (!ranToCompletion) { |
