mirror of https://github.com/jellyfin/jellyfin.git
updated nuget
This commit is contained in:
parent
4fa822c00d
commit
1fba8d077b
|
@ -35,7 +35,13 @@ namespace MediaBrowser.Model.ApiClient
|
||||||
/// Occurs when [remote logged out].
|
/// Occurs when [remote logged out].
|
||||||
/// </summary>
|
/// </summary>
|
||||||
event EventHandler<EventArgs> RemoteLoggedOut;
|
event EventHandler<EventArgs> RemoteLoggedOut;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Gets the device.
|
||||||
|
/// </summary>
|
||||||
|
/// <value>The device.</value>
|
||||||
|
IDevice Device { get; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets the connect user.
|
/// Gets the connect user.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
|
@ -316,12 +316,14 @@ namespace MediaBrowser.Model.Dlna
|
||||||
|
|
||||||
MediaStream videoStream = item.VideoStream;
|
MediaStream videoStream = item.VideoStream;
|
||||||
|
|
||||||
int? maxBitrateSetting = options.GetMaxBitrate();
|
// TODO: This doesn't accout for situation of device being able to handle media bitrate, but wifi connection not fast enough
|
||||||
|
bool isEligibleForDirectPlay = IsEligibleForDirectPlay(item, options.Profile.MaxStaticBitrate, subtitleStream, options);
|
||||||
|
bool isEligibleForDirectStream = IsEligibleForDirectPlay(item, options.GetMaxBitrate(), subtitleStream, options);
|
||||||
|
|
||||||
if (IsEligibleForDirectPlay(item, maxBitrateSetting, subtitleStream, options))
|
if (isEligibleForDirectPlay || isEligibleForDirectStream)
|
||||||
{
|
{
|
||||||
// See if it can be direct played
|
// See if it can be direct played
|
||||||
var directPlay = GetVideoDirectPlayProfile(options, options.Profile, item, videoStream, audioStream);
|
PlayMethod? directPlay = GetVideoDirectPlayProfile(options.Profile, item, videoStream, audioStream, isEligibleForDirectPlay, isEligibleForDirectStream);
|
||||||
|
|
||||||
if (directPlay != null)
|
if (directPlay != null)
|
||||||
{
|
{
|
||||||
|
@ -416,6 +418,7 @@ namespace MediaBrowser.Model.Dlna
|
||||||
playlistItem.AudioBitrate = GetAudioBitrate(playlistItem.TargetAudioChannels, playlistItem.TargetAudioCodec);
|
playlistItem.AudioBitrate = GetAudioBitrate(playlistItem.TargetAudioChannels, playlistItem.TargetAudioCodec);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int? maxBitrateSetting = options.GetMaxBitrate();
|
||||||
// Honor max rate
|
// Honor max rate
|
||||||
if (maxBitrateSetting.HasValue)
|
if (maxBitrateSetting.HasValue)
|
||||||
{
|
{
|
||||||
|
@ -448,11 +451,12 @@ namespace MediaBrowser.Model.Dlna
|
||||||
return 128000;
|
return 128000;
|
||||||
}
|
}
|
||||||
|
|
||||||
private PlayMethod? GetVideoDirectPlayProfile(VideoOptions options,
|
private PlayMethod? GetVideoDirectPlayProfile(DeviceProfile profile,
|
||||||
DeviceProfile profile,
|
|
||||||
MediaSourceInfo mediaSource,
|
MediaSourceInfo mediaSource,
|
||||||
MediaStream videoStream,
|
MediaStream videoStream,
|
||||||
MediaStream audioStream)
|
MediaStream audioStream,
|
||||||
|
bool isEligibleForDirectPlay,
|
||||||
|
bool isEligibleForDirectStream)
|
||||||
{
|
{
|
||||||
// See if it can be direct played
|
// See if it can be direct played
|
||||||
DirectPlayProfile directPlay = null;
|
DirectPlayProfile directPlay = null;
|
||||||
|
@ -571,28 +575,34 @@ namespace MediaBrowser.Model.Dlna
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (mediaSource.Protocol == MediaProtocol.Http)
|
if (isEligibleForDirectPlay)
|
||||||
{
|
{
|
||||||
if (_localPlayer.CanAccessUrl(mediaSource.Path, mediaSource.RequiredHttpHeaders.Count > 0))
|
if (mediaSource.Protocol == MediaProtocol.Http)
|
||||||
{
|
{
|
||||||
return PlayMethod.DirectPlay;
|
if (_localPlayer.CanAccessUrl(mediaSource.Path, mediaSource.RequiredHttpHeaders.Count > 0))
|
||||||
|
{
|
||||||
|
return PlayMethod.DirectPlay;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
else if (mediaSource.Protocol == MediaProtocol.File)
|
||||||
|
{
|
||||||
|
if (_localPlayer.CanAccessFile(mediaSource.Path))
|
||||||
|
{
|
||||||
|
return PlayMethod.DirectPlay;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
else if (mediaSource.Protocol == MediaProtocol.File)
|
if (isEligibleForDirectStream)
|
||||||
{
|
{
|
||||||
if (_localPlayer.CanAccessFile(mediaSource.Path))
|
if (mediaSource.SupportsDirectStream)
|
||||||
{
|
{
|
||||||
return PlayMethod.DirectPlay;
|
return PlayMethod.DirectStream;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!mediaSource.SupportsDirectStream)
|
return null;
|
||||||
{
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
|
|
||||||
return PlayMethod.DirectStream;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private bool IsEligibleForDirectPlay(MediaSourceInfo item,
|
private bool IsEligibleForDirectPlay(MediaSourceInfo item,
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
<package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd">
|
<package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd">
|
||||||
<metadata>
|
<metadata>
|
||||||
<id>MediaBrowser.Common.Internal</id>
|
<id>MediaBrowser.Common.Internal</id>
|
||||||
<version>3.0.595</version>
|
<version>3.0.597</version>
|
||||||
<title>MediaBrowser.Common.Internal</title>
|
<title>MediaBrowser.Common.Internal</title>
|
||||||
<authors>Luke</authors>
|
<authors>Luke</authors>
|
||||||
<owners>ebr,Luke,scottisafool</owners>
|
<owners>ebr,Luke,scottisafool</owners>
|
||||||
|
@ -12,7 +12,7 @@
|
||||||
<description>Contains common components shared by Media Browser Theater and Media Browser Server. Not intended for plugin developer consumption.</description>
|
<description>Contains common components shared by Media Browser Theater and Media Browser Server. Not intended for plugin developer consumption.</description>
|
||||||
<copyright>Copyright © Media Browser 2013</copyright>
|
<copyright>Copyright © Media Browser 2013</copyright>
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<dependency id="MediaBrowser.Common" version="3.0.595" />
|
<dependency id="MediaBrowser.Common" version="3.0.597" />
|
||||||
<dependency id="NLog" version="3.2.0.0" />
|
<dependency id="NLog" version="3.2.0.0" />
|
||||||
<dependency id="SimpleInjector" version="2.7.0" />
|
<dependency id="SimpleInjector" version="2.7.0" />
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
<package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd">
|
<package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd">
|
||||||
<metadata>
|
<metadata>
|
||||||
<id>MediaBrowser.Common</id>
|
<id>MediaBrowser.Common</id>
|
||||||
<version>3.0.595</version>
|
<version>3.0.597</version>
|
||||||
<title>MediaBrowser.Common</title>
|
<title>MediaBrowser.Common</title>
|
||||||
<authors>Media Browser Team</authors>
|
<authors>Media Browser Team</authors>
|
||||||
<owners>ebr,Luke,scottisafool</owners>
|
<owners>ebr,Luke,scottisafool</owners>
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
<package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd">
|
<package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd">
|
||||||
<metadata>
|
<metadata>
|
||||||
<id>MediaBrowser.Model.Signed</id>
|
<id>MediaBrowser.Model.Signed</id>
|
||||||
<version>3.0.595</version>
|
<version>3.0.597</version>
|
||||||
<title>MediaBrowser.Model - Signed Edition</title>
|
<title>MediaBrowser.Model - Signed Edition</title>
|
||||||
<authors>Media Browser Team</authors>
|
<authors>Media Browser Team</authors>
|
||||||
<owners>ebr,Luke,scottisafool</owners>
|
<owners>ebr,Luke,scottisafool</owners>
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd">
|
<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd">
|
||||||
<metadata>
|
<metadata>
|
||||||
<id>MediaBrowser.Server.Core</id>
|
<id>MediaBrowser.Server.Core</id>
|
||||||
<version>3.0.595</version>
|
<version>3.0.597</version>
|
||||||
<title>Media Browser.Server.Core</title>
|
<title>Media Browser.Server.Core</title>
|
||||||
<authors>Media Browser Team</authors>
|
<authors>Media Browser Team</authors>
|
||||||
<owners>ebr,Luke,scottisafool</owners>
|
<owners>ebr,Luke,scottisafool</owners>
|
||||||
|
@ -12,7 +12,7 @@
|
||||||
<description>Contains core components required to build plugins for Media Browser Server.</description>
|
<description>Contains core components required to build plugins for Media Browser Server.</description>
|
||||||
<copyright>Copyright © Media Browser 2013</copyright>
|
<copyright>Copyright © Media Browser 2013</copyright>
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<dependency id="MediaBrowser.Common" version="3.0.595" />
|
<dependency id="MediaBrowser.Common" version="3.0.597" />
|
||||||
</dependencies>
|
</dependencies>
|
||||||
</metadata>
|
</metadata>
|
||||||
<files>
|
<files>
|
||||||
|
|
Loading…
Reference in New Issue