Merge pull request #2514 from MediaBrowser/dev
update legacy hd homerun support
This commit is contained in:
commit
82bb69213e
|
@ -83,6 +83,12 @@ namespace Emby.Dlna.Profiles
|
||||||
{
|
{
|
||||||
Format = "srt",
|
Format = "srt",
|
||||||
Method = SubtitleDeliveryMethod.Embed
|
Method = SubtitleDeliveryMethod.Embed
|
||||||
|
},
|
||||||
|
|
||||||
|
new SubtitleProfile
|
||||||
|
{
|
||||||
|
Format = "srt",
|
||||||
|
Method = SubtitleDeliveryMethod.External,
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -113,6 +113,15 @@ namespace Emby.Dlna.Profiles
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
SubtitleProfiles = new[]
|
||||||
|
{
|
||||||
|
new SubtitleProfile
|
||||||
|
{
|
||||||
|
Format = "srt",
|
||||||
|
Method = SubtitleDeliveryMethod.Embed
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
ResponseProfiles = new ResponseProfile[] { };
|
ResponseProfiles = new ResponseProfile[] { };
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -214,6 +214,14 @@ namespace Emby.Dlna.Profiles
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
SubtitleProfiles = new[]
|
||||||
|
{
|
||||||
|
new SubtitleProfile
|
||||||
|
{
|
||||||
|
Format = "srt",
|
||||||
|
Method = SubtitleDeliveryMethod.Embed
|
||||||
|
}
|
||||||
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -40,6 +40,15 @@ namespace Emby.Dlna.Profiles
|
||||||
MimeType = "video/mp4"
|
MimeType = "video/mp4"
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
SubtitleProfiles = new[]
|
||||||
|
{
|
||||||
|
new SubtitleProfile
|
||||||
|
{
|
||||||
|
Format = "srt",
|
||||||
|
Method = SubtitleDeliveryMethod.Embed
|
||||||
|
}
|
||||||
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -210,6 +210,15 @@ namespace Emby.Dlna.Profiles
|
||||||
MimeType = "video/mp4"
|
MimeType = "video/mp4"
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
SubtitleProfiles = new[]
|
||||||
|
{
|
||||||
|
new SubtitleProfile
|
||||||
|
{
|
||||||
|
Format = "srt",
|
||||||
|
Method = SubtitleDeliveryMethod.Embed
|
||||||
|
}
|
||||||
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -269,6 +269,15 @@ namespace Emby.Dlna.Profiles
|
||||||
Type = DlnaProfileType.Audio
|
Type = DlnaProfileType.Audio
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
SubtitleProfiles = new[]
|
||||||
|
{
|
||||||
|
new SubtitleProfile
|
||||||
|
{
|
||||||
|
Format = "srt",
|
||||||
|
Method = SubtitleDeliveryMethod.Embed
|
||||||
|
}
|
||||||
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -351,6 +351,15 @@ namespace Emby.Dlna.Profiles
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
SubtitleProfiles = new[]
|
||||||
|
{
|
||||||
|
new SubtitleProfile
|
||||||
|
{
|
||||||
|
Format = "srt",
|
||||||
|
Method = SubtitleDeliveryMethod.Embed
|
||||||
|
}
|
||||||
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -374,6 +374,15 @@ namespace Emby.Dlna.Profiles
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
SubtitleProfiles = new[]
|
||||||
|
{
|
||||||
|
new SubtitleProfile
|
||||||
|
{
|
||||||
|
Format = "srt",
|
||||||
|
Method = SubtitleDeliveryMethod.Embed
|
||||||
|
}
|
||||||
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -292,6 +292,15 @@ namespace Emby.Dlna.Profiles
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
SubtitleProfiles = new[]
|
||||||
|
{
|
||||||
|
new SubtitleProfile
|
||||||
|
{
|
||||||
|
Format = "srt",
|
||||||
|
Method = SubtitleDeliveryMethod.Embed
|
||||||
|
}
|
||||||
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -310,6 +310,15 @@ namespace Emby.Dlna.Profiles
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
SubtitleProfiles = new[]
|
||||||
|
{
|
||||||
|
new SubtitleProfile
|
||||||
|
{
|
||||||
|
Format = "srt",
|
||||||
|
Method = SubtitleDeliveryMethod.Embed
|
||||||
|
}
|
||||||
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -310,6 +310,15 @@ namespace Emby.Dlna.Profiles
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
SubtitleProfiles = new[]
|
||||||
|
{
|
||||||
|
new SubtitleProfile
|
||||||
|
{
|
||||||
|
Format = "srt",
|
||||||
|
Method = SubtitleDeliveryMethod.Embed
|
||||||
|
}
|
||||||
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -255,6 +255,15 @@ namespace Emby.Dlna.Profiles
|
||||||
Type = DlnaProfileType.Audio
|
Type = DlnaProfileType.Audio
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
SubtitleProfiles = new[]
|
||||||
|
{
|
||||||
|
new SubtitleProfile
|
||||||
|
{
|
||||||
|
Format = "srt",
|
||||||
|
Method = SubtitleDeliveryMethod.Embed
|
||||||
|
}
|
||||||
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -264,6 +264,15 @@ namespace Emby.Dlna.Profiles
|
||||||
MimeType = "video/mp4"
|
MimeType = "video/mp4"
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
SubtitleProfiles = new[]
|
||||||
|
{
|
||||||
|
new SubtitleProfile
|
||||||
|
{
|
||||||
|
Format = "srt",
|
||||||
|
Method = SubtitleDeliveryMethod.Embed
|
||||||
|
}
|
||||||
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -312,6 +312,15 @@ namespace Emby.Dlna.Profiles
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
SubtitleProfiles = new[]
|
||||||
|
{
|
||||||
|
new SubtitleProfile
|
||||||
|
{
|
||||||
|
Format = "srt",
|
||||||
|
Method = SubtitleDeliveryMethod.Embed
|
||||||
|
}
|
||||||
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -357,6 +357,15 @@ namespace Emby.Dlna.Profiles
|
||||||
MimeType = "video/mp4"
|
MimeType = "video/mp4"
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
SubtitleProfiles = new[]
|
||||||
|
{
|
||||||
|
new SubtitleProfile
|
||||||
|
{
|
||||||
|
Format = "srt",
|
||||||
|
Method = SubtitleDeliveryMethod.Embed
|
||||||
|
}
|
||||||
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -46,5 +46,6 @@
|
||||||
</ResponseProfiles>
|
</ResponseProfiles>
|
||||||
<SubtitleProfiles>
|
<SubtitleProfiles>
|
||||||
<SubtitleProfile format="srt" method="Embed" />
|
<SubtitleProfile format="srt" method="Embed" />
|
||||||
|
<SubtitleProfile format="srt" method="External" />
|
||||||
</SubtitleProfiles>
|
</SubtitleProfiles>
|
||||||
</Profile>
|
</Profile>
|
|
@ -46,5 +46,6 @@
|
||||||
<ResponseProfiles />
|
<ResponseProfiles />
|
||||||
<SubtitleProfiles>
|
<SubtitleProfiles>
|
||||||
<SubtitleProfile format="srt" method="Embed" />
|
<SubtitleProfile format="srt" method="Embed" />
|
||||||
|
<SubtitleProfile format="srt" method="External" />
|
||||||
</SubtitleProfiles>
|
</SubtitleProfiles>
|
||||||
</Profile>
|
</Profile>
|
|
@ -52,5 +52,6 @@
|
||||||
<ResponseProfiles />
|
<ResponseProfiles />
|
||||||
<SubtitleProfiles>
|
<SubtitleProfiles>
|
||||||
<SubtitleProfile format="srt" method="Embed" />
|
<SubtitleProfile format="srt" method="Embed" />
|
||||||
|
<SubtitleProfile format="srt" method="External" />
|
||||||
</SubtitleProfiles>
|
</SubtitleProfiles>
|
||||||
</Profile>
|
</Profile>
|
|
@ -52,5 +52,6 @@
|
||||||
<ResponseProfiles />
|
<ResponseProfiles />
|
||||||
<SubtitleProfiles>
|
<SubtitleProfiles>
|
||||||
<SubtitleProfile format="srt" method="Embed" />
|
<SubtitleProfile format="srt" method="Embed" />
|
||||||
|
<SubtitleProfile format="srt" method="External" />
|
||||||
</SubtitleProfiles>
|
</SubtitleProfiles>
|
||||||
</Profile>
|
</Profile>
|
|
@ -195,13 +195,12 @@ namespace Emby.Server.Implementations.Devices
|
||||||
}
|
}
|
||||||
|
|
||||||
var config = _config.GetUploadOptions();
|
var config = _config.GetUploadOptions();
|
||||||
if (!string.IsNullOrWhiteSpace(config.CameraUploadPath))
|
var path = config.CameraUploadPath;
|
||||||
|
if (string.IsNullOrWhiteSpace(path))
|
||||||
{
|
{
|
||||||
return config.CameraUploadPath;
|
path = DefaultCameraUploadsPath;
|
||||||
}
|
}
|
||||||
|
|
||||||
var path = DefaultCameraUploadsPath;
|
|
||||||
|
|
||||||
if (config.EnableCameraUploadSubfolders)
|
if (config.EnableCameraUploadSubfolders)
|
||||||
{
|
{
|
||||||
path = Path.Combine(path, _fileSystem.GetValidFilename(device.Name));
|
path = Path.Combine(path, _fileSystem.GetValidFilename(device.Name));
|
||||||
|
|
|
@ -409,18 +409,41 @@ namespace Emby.Server.Implementations.Library
|
||||||
|
|
||||||
if (options.DeleteFileLocation && locationType != LocationType.Remote && locationType != LocationType.Virtual)
|
if (options.DeleteFileLocation && locationType != LocationType.Remote && locationType != LocationType.Virtual)
|
||||||
{
|
{
|
||||||
|
// Assume only the first is required
|
||||||
|
// Add this flag to GetDeletePaths if required in the future
|
||||||
|
var isRequiredForDelete = true;
|
||||||
|
|
||||||
foreach (var fileSystemInfo in item.GetDeletePaths().ToList())
|
foreach (var fileSystemInfo in item.GetDeletePaths().ToList())
|
||||||
{
|
{
|
||||||
if (fileSystemInfo.IsDirectory)
|
try
|
||||||
{
|
{
|
||||||
_logger.Debug("Deleting path {0}", fileSystemInfo.FullName);
|
if (fileSystemInfo.IsDirectory)
|
||||||
_fileSystem.DeleteDirectory(fileSystemInfo.FullName, true);
|
{
|
||||||
|
_logger.Debug("Deleting path {0}", fileSystemInfo.FullName);
|
||||||
|
_fileSystem.DeleteDirectory(fileSystemInfo.FullName, true);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
_logger.Debug("Deleting path {0}", fileSystemInfo.FullName);
|
||||||
|
_fileSystem.DeleteFile(fileSystemInfo.FullName);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
catch (IOException)
|
||||||
{
|
{
|
||||||
_logger.Debug("Deleting path {0}", fileSystemInfo.FullName);
|
if (isRequiredForDelete)
|
||||||
_fileSystem.DeleteFile(fileSystemInfo.FullName);
|
{
|
||||||
|
throw;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
catch (UnauthorizedAccessException)
|
||||||
|
{
|
||||||
|
if (isRequiredForDelete)
|
||||||
|
{
|
||||||
|
throw;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
isRequiredForDelete = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (parent != null)
|
if (parent != null)
|
||||||
|
|
|
@ -434,6 +434,11 @@ namespace Emby.Server.Implementations.Library
|
||||||
Policy = user.Policy
|
Policy = user.Policy
|
||||||
};
|
};
|
||||||
|
|
||||||
|
if (!hasPassword && Users.Count() == 1)
|
||||||
|
{
|
||||||
|
dto.EnableAutoLogin = true;
|
||||||
|
}
|
||||||
|
|
||||||
var image = user.GetImageInfo(ImageType.Primary, 0);
|
var image = user.GetImageInfo(ImageType.Primary, 0);
|
||||||
|
|
||||||
if (image != null)
|
if (image != null)
|
||||||
|
|
|
@ -596,6 +596,7 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts.HdHomerun
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
var mediaSource = GetMediaSource(info, hdhrId, channelInfo, profile);
|
var mediaSource = GetMediaSource(info, hdhrId, channelInfo, profile);
|
||||||
|
//var modelInfo = await GetModelInfo(info, false, cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
return new HdHomerunHttpStream(mediaSource, streamId, _fileSystem, _httpClient, Logger, Config.ApplicationPaths, _appHost);
|
return new HdHomerunHttpStream(mediaSource, streamId, _fileSystem, _httpClient, Logger, Config.ApplicationPaths, _appHost);
|
||||||
//return new HdHomerunUdpStream(mediaSource, streamId, new HdHomerunChannelCommands(hdhomerunChannel.Number), modelInfo.TunerCount, _fileSystem, _httpClient, Logger, Config.ApplicationPaths, _appHost, _socketFactory, _networkManager);
|
//return new HdHomerunUdpStream(mediaSource, streamId, new HdHomerunChannelCommands(hdhomerunChannel.Number), modelInfo.TunerCount, _fileSystem, _httpClient, Logger, Config.ApplicationPaths, _appHost, _socketFactory, _networkManager);
|
||||||
|
|
|
@ -145,7 +145,7 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts.HdHomerun
|
||||||
{
|
{
|
||||||
var channelMsg = CreateSetMessage(i, command.Item1, command.Item2, _lockkey.Value);
|
var channelMsg = CreateSetMessage(i, command.Item1, command.Item2, _lockkey.Value);
|
||||||
await tcpClient.SendAsync(channelMsg, channelMsg.Length, ipEndPoint, cancellationToken).ConfigureAwait(false);
|
await tcpClient.SendAsync(channelMsg, channelMsg.Length, ipEndPoint, cancellationToken).ConfigureAwait(false);
|
||||||
await tcpClient.ReceiveAsync(cancellationToken).ConfigureAwait(false);
|
response = await tcpClient.ReceiveAsync(cancellationToken).ConfigureAwait(false);
|
||||||
// parse response to make sure it worked
|
// parse response to make sure it worked
|
||||||
if (!ParseReturnMessage(response.Buffer, response.ReceivedBytes, out returnVal))
|
if (!ParseReturnMessage(response.Buffer, response.ReceivedBytes, out returnVal))
|
||||||
{
|
{
|
||||||
|
@ -172,6 +172,29 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts.HdHomerun
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public async Task ChangeChannel(IHdHomerunChannelCommands commands, CancellationToken cancellationToken)
|
||||||
|
{
|
||||||
|
if (!_lockkey.HasValue)
|
||||||
|
return;
|
||||||
|
|
||||||
|
using (var tcpClient = _socketFactory.CreateTcpSocket(_remoteIp, HdHomeRunPort))
|
||||||
|
{
|
||||||
|
var commandList = commands.GetCommands();
|
||||||
|
foreach (Tuple<string, string> command in commandList)
|
||||||
|
{
|
||||||
|
var channelMsg = CreateSetMessage(_activeTuner, command.Item1, command.Item2, _lockkey.Value);
|
||||||
|
await tcpClient.SendAsync(channelMsg, channelMsg.Length, new IpEndPointInfo(_remoteIp, HdHomeRunPort), cancellationToken).ConfigureAwait(false);
|
||||||
|
var response = await tcpClient.ReceiveAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
// parse response to make sure it worked
|
||||||
|
string returnVal;
|
||||||
|
if (!ParseReturnMessage(response.Buffer, response.ReceivedBytes, out returnVal))
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public async Task StopStreaming()
|
public async Task StopStreaming()
|
||||||
{
|
{
|
||||||
if (!_lockkey.HasValue)
|
if (!_lockkey.HasValue)
|
||||||
|
|
|
@ -179,6 +179,11 @@ namespace MediaBrowser.Controller.MediaEncoding
|
||||||
{
|
{
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
// Seeing reported failures here, not sure yet if this is related to specfying input format
|
||||||
|
if (string.Equals(container, "m4v", StringComparison.OrdinalIgnoreCase))
|
||||||
|
{
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
return container;
|
return container;
|
||||||
}
|
}
|
||||||
|
|
|
@ -90,6 +90,8 @@ namespace MediaBrowser.Model.Dto
|
||||||
/// <value><c>true</c> if this instance has configured easy password; otherwise, <c>false</c>.</value>
|
/// <value><c>true</c> if this instance has configured easy password; otherwise, <c>false</c>.</value>
|
||||||
public bool HasConfiguredEasyPassword { get; set; }
|
public bool HasConfiguredEasyPassword { get; set; }
|
||||||
|
|
||||||
|
public bool? EnableAutoLogin { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets the last login date.
|
/// Gets or sets the last login date.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
|
|
||||||
[assembly: AssemblyVersion("3.2.5.7")]
|
[assembly: AssemblyVersion("3.2.6.1")]
|
||||||
|
|
Loading…
Reference in New Issue
Block a user