|
|
|
@ -246,9 +246,9 @@ namespace Emby.Server.Implementations.LiveTv
|
|
|
|
|
return info.Item1;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public async Task<Tuple<MediaSourceInfo, IDirectStreamProvider>> GetChannelStream(string id, string mediaSourceId, CancellationToken cancellationToken)
|
|
|
|
|
public Task<Tuple<MediaSourceInfo, IDirectStreamProvider, bool>> GetChannelStream(string id, string mediaSourceId, CancellationToken cancellationToken)
|
|
|
|
|
{
|
|
|
|
|
return await GetLiveStream(id, mediaSourceId, true, cancellationToken).ConfigureAwait(false);
|
|
|
|
|
return GetLiveStream(id, mediaSourceId, true, cancellationToken);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private string GetItemExternalId(BaseItem item)
|
|
|
|
@ -308,7 +308,7 @@ namespace Emby.Server.Implementations.LiveTv
|
|
|
|
|
return _services.FirstOrDefault(i => string.Equals(i.Name, name, StringComparison.OrdinalIgnoreCase));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private async Task<Tuple<MediaSourceInfo, IDirectStreamProvider>> GetLiveStream(string id, string mediaSourceId, bool isChannel, CancellationToken cancellationToken)
|
|
|
|
|
private async Task<Tuple<MediaSourceInfo, IDirectStreamProvider, bool>> GetLiveStream(string id, string mediaSourceId, bool isChannel, CancellationToken cancellationToken)
|
|
|
|
|
{
|
|
|
|
|
if (string.Equals(id, mediaSourceId, StringComparison.OrdinalIgnoreCase))
|
|
|
|
|
{
|
|
|
|
@ -319,6 +319,7 @@ namespace Emby.Server.Implementations.LiveTv
|
|
|
|
|
bool isVideo;
|
|
|
|
|
ILiveTvService service;
|
|
|
|
|
IDirectStreamProvider directStreamProvider = null;
|
|
|
|
|
var assumeInterlaced = false;
|
|
|
|
|
|
|
|
|
|
if (isChannel)
|
|
|
|
|
{
|
|
|
|
@ -367,7 +368,12 @@ namespace Emby.Server.Implementations.LiveTv
|
|
|
|
|
|
|
|
|
|
Normalize(info, service, isVideo);
|
|
|
|
|
|
|
|
|
|
return new Tuple<MediaSourceInfo, IDirectStreamProvider>(info, directStreamProvider);
|
|
|
|
|
if (!(service is EmbyTV.EmbyTV))
|
|
|
|
|
{
|
|
|
|
|
assumeInterlaced = true;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return new Tuple<MediaSourceInfo, IDirectStreamProvider, bool>(info, directStreamProvider, assumeInterlaced);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private void Normalize(MediaSourceInfo mediaSource, ILiveTvService service, bool isVideo)
|
|
|
|
|