aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Model
diff options
context:
space:
mode:
authorLuke <luke.pulverenti@gmail.com>2017-05-06 16:20:25 -0400
committerGitHub <noreply@github.com>2017-05-06 16:20:25 -0400
commit21edff3ac2175190e0bca98c9a2f967c79ee57c2 (patch)
tree6beddce4dffa97eb199da99867f6b493ce197e64 /MediaBrowser.Model
parent3e29d73d0c77c682e161c413703d5e36a8466885 (diff)
parent90452d2faf5e0f34698873707e9e505df3c52f9c (diff)
Merge pull request #2618 from MediaBrowser/beta
Beta
Diffstat (limited to 'MediaBrowser.Model')
-rw-r--r--MediaBrowser.Model/Configuration/ServerConfiguration.cs3
-rw-r--r--MediaBrowser.Model/Dlna/ResolutionNormalizer.cs35
-rw-r--r--MediaBrowser.Model/Dto/BaseItemDto.cs6
-rw-r--r--MediaBrowser.Model/Dto/MediaSourceInfo.cs2
-rw-r--r--MediaBrowser.Model/IO/IFileSystem.cs2
-rw-r--r--MediaBrowser.Model/Querying/ItemFields.cs7
-rw-r--r--MediaBrowser.Model/Search/SearchHint.cs11
-rw-r--r--MediaBrowser.Model/Search/SearchQuery.cs11
-rw-r--r--MediaBrowser.Model/Session/GeneralCommandType.cs3
-rw-r--r--MediaBrowser.Model/Users/UserPolicy.cs2
10 files changed, 51 insertions, 31 deletions
diff --git a/MediaBrowser.Model/Configuration/ServerConfiguration.cs b/MediaBrowser.Model/Configuration/ServerConfiguration.cs
index 9d795cfab3..838111a383 100644
--- a/MediaBrowser.Model/Configuration/ServerConfiguration.cs
+++ b/MediaBrowser.Model/Configuration/ServerConfiguration.cs
@@ -68,6 +68,8 @@ namespace MediaBrowser.Model.Configuration
/// <value><c>true</c> if [enable case sensitive item ids]; otherwise, <c>false</c>.</value>
public bool EnableCaseSensitiveItemIds { get; set; }
+ public bool DisableLiveTvChannelUserDataName { get; set; }
+
/// <summary>
/// Gets or sets the metadata path.
/// </summary>
@@ -162,7 +164,6 @@ namespace MediaBrowser.Model.Configuration
public bool EnableAutomaticRestart { get; set; }
public bool SkipDeserializationForBasicTypes { get; set; }
- public bool SkipDeserializationForPrograms { get; set; }
public bool SkipDeserializationForAudio { get; set; }
public string ServerName { get; set; }
diff --git a/MediaBrowser.Model/Dlna/ResolutionNormalizer.cs b/MediaBrowser.Model/Dlna/ResolutionNormalizer.cs
index b0760d91f2..950d3680df 100644
--- a/MediaBrowser.Model/Dlna/ResolutionNormalizer.cs
+++ b/MediaBrowser.Model/Dlna/ResolutionNormalizer.cs
@@ -12,7 +12,9 @@ namespace MediaBrowser.Model.Dlna
new ResolutionConfiguration(426, 320000),
new ResolutionConfiguration(640, 400000),
new ResolutionConfiguration(720, 950000),
- new ResolutionConfiguration(1280, 2500000)
+ new ResolutionConfiguration(1280, 2500000),
+ new ResolutionConfiguration(1920, 4000000),
+ new ResolutionConfiguration(3840, 35000000)
};
public static ResolutionOptions Normalize(int? inputBitrate,
@@ -35,19 +37,15 @@ namespace MediaBrowser.Model.Dlna
}
}
- foreach (var config in Configurations)
+ var resolutionConfig = GetResolutionConfiguration(outputBitrate);
+ if (resolutionConfig != null)
{
- if (outputBitrate <= config.MaxBitrate)
- {
- var originvalValue = maxWidth;
-
- maxWidth = Math.Min(config.MaxWidth, maxWidth ?? config.MaxWidth);
- if (!originvalValue.HasValue || originvalValue.Value != maxWidth.Value)
- {
- maxHeight = null;
- }
+ var originvalValue = maxWidth;
- break;
+ maxWidth = Math.Min(resolutionConfig.MaxWidth, maxWidth ?? resolutionConfig.MaxWidth);
+ if (!originvalValue.HasValue || originvalValue.Value != maxWidth.Value)
+ {
+ maxHeight = null;
}
}
@@ -58,6 +56,19 @@ namespace MediaBrowser.Model.Dlna
};
}
+ private static ResolutionConfiguration GetResolutionConfiguration(int outputBitrate)
+ {
+ foreach (var config in Configurations)
+ {
+ if (outputBitrate <= config.MaxBitrate)
+ {
+ return config;
+ }
+ }
+
+ return null;
+ }
+
private static double GetVideoBitrateScaleFactor(string codec)
{
if (StringHelper.EqualsIgnoreCase(codec, "h265") ||
diff --git a/MediaBrowser.Model/Dto/BaseItemDto.cs b/MediaBrowser.Model/Dto/BaseItemDto.cs
index ae7d138680..1a752892ee 100644
--- a/MediaBrowser.Model/Dto/BaseItemDto.cs
+++ b/MediaBrowser.Model/Dto/BaseItemDto.cs
@@ -165,12 +165,6 @@ namespace MediaBrowser.Model.Dto
public string[] ProductionLocations { get; set; }
- /// <summary>
- /// Gets or sets the critic rating summary.
- /// </summary>
- /// <value>The critic rating summary.</value>
- public string CriticRatingSummary { get; set; }
-
public List<string> MultiPartGameFiles { get; set; }
/// <summary>
diff --git a/MediaBrowser.Model/Dto/MediaSourceInfo.cs b/MediaBrowser.Model/Dto/MediaSourceInfo.cs
index 1315830247..d0655d90bc 100644
--- a/MediaBrowser.Model/Dto/MediaSourceInfo.cs
+++ b/MediaBrowser.Model/Dto/MediaSourceInfo.cs
@@ -29,6 +29,8 @@ namespace MediaBrowser.Model.Dto
public string ETag { get; set; }
public long? RunTimeTicks { get; set; }
public bool ReadAtNativeFramerate { get; set; }
+ public bool IgnoreDts { get; set; }
+ public bool IgnoreIndex { get; set; }
public bool SupportsTranscoding { get; set; }
public bool SupportsDirectStream { get; set; }
public bool SupportsDirectPlay { get; set; }
diff --git a/MediaBrowser.Model/IO/IFileSystem.cs b/MediaBrowser.Model/IO/IFileSystem.cs
index 6773acbfac..26de9332e3 100644
--- a/MediaBrowser.Model/IO/IFileSystem.cs
+++ b/MediaBrowser.Model/IO/IFileSystem.cs
@@ -146,6 +146,8 @@ namespace MediaBrowser.Model.IO
/// <returns>System.String.</returns>
string NormalizePath(string path);
+ string GetDirectoryName(string path);
+
/// <summary>
/// Gets the file name without extension.
/// </summary>
diff --git a/MediaBrowser.Model/Querying/ItemFields.cs b/MediaBrowser.Model/Querying/ItemFields.cs
index 0caf645386..75ba09b609 100644
--- a/MediaBrowser.Model/Querying/ItemFields.cs
+++ b/MediaBrowser.Model/Querying/ItemFields.cs
@@ -43,11 +43,6 @@
ChildCount,
/// <summary>
- /// The critic rating summary
- /// </summary>
- CriticRatingSummary,
-
- /// <summary>
/// The cumulative run time ticks
/// </summary>
CumulativeRunTimeTicks,
@@ -122,8 +117,6 @@
/// </summary>
MediaSources,
- OfficialRatingDescription,
-
OriginalTitle,
/// <summary>
diff --git a/MediaBrowser.Model/Search/SearchHint.cs b/MediaBrowser.Model/Search/SearchHint.cs
index cea15a2a78..3ca0eafe63 100644
--- a/MediaBrowser.Model/Search/SearchHint.cs
+++ b/MediaBrowser.Model/Search/SearchHint.cs
@@ -1,4 +1,6 @@
-namespace MediaBrowser.Model.Search
+using System;
+
+namespace MediaBrowser.Model.Search
{
/// <summary>
/// Class SearchHintResult
@@ -94,13 +96,18 @@
/// </summary>
/// <value>The display type of the media.</value>
public string DisplayMediaType { get; set; }
-
+
+ public DateTime? StartDate { get; set; }
+ public DateTime? EndDate { get; set; }
+
/// <summary>
/// Gets or sets the series.
/// </summary>
/// <value>The series.</value>
public string Series { get; set; }
+ public string Status { get; set; }
+
/// <summary>
/// Gets or sets the album.
/// </summary>
diff --git a/MediaBrowser.Model/Search/SearchQuery.cs b/MediaBrowser.Model/Search/SearchQuery.cs
index 678dfd39d7..897a9db523 100644
--- a/MediaBrowser.Model/Search/SearchQuery.cs
+++ b/MediaBrowser.Model/Search/SearchQuery.cs
@@ -34,6 +34,17 @@ namespace MediaBrowser.Model.Search
public bool IncludeArtists { get; set; }
public string[] IncludeItemTypes { get; set; }
+ public string ParentId { get; set; }
+
+ public bool? IsMovie { get; set; }
+
+ public bool? IsSeries { get; set; }
+
+ public bool? IsNews { get; set; }
+
+ public bool? IsKids { get; set; }
+
+ public bool? IsSports { get; set; }
public SearchQuery()
{
diff --git a/MediaBrowser.Model/Session/GeneralCommandType.cs b/MediaBrowser.Model/Session/GeneralCommandType.cs
index 6cceb162a4..1a96515599 100644
--- a/MediaBrowser.Model/Session/GeneralCommandType.cs
+++ b/MediaBrowser.Model/Session/GeneralCommandType.cs
@@ -37,6 +37,7 @@
SetRepeatMode = 29,
ChannelUp = 30,
ChannelDown = 31,
- SetMaxStreamingBitrate = 31
+ SetMaxStreamingBitrate = 31,
+ Guide = 32
}
} \ No newline at end of file
diff --git a/MediaBrowser.Model/Users/UserPolicy.cs b/MediaBrowser.Model/Users/UserPolicy.cs
index 3917b1662d..2a987ceb14 100644
--- a/MediaBrowser.Model/Users/UserPolicy.cs
+++ b/MediaBrowser.Model/Users/UserPolicy.cs
@@ -50,7 +50,6 @@ namespace MediaBrowser.Model.Users
/// Gets or sets a value indicating whether [enable synchronize].
/// </summary>
/// <value><c>true</c> if [enable synchronize]; otherwise, <c>false</c>.</value>
- public bool EnableSync { get; set; }
public bool EnableSyncTranscoding { get; set; }
public string[] EnabledDevices { get; set; }
@@ -71,7 +70,6 @@ namespace MediaBrowser.Model.Users
public UserPolicy()
{
- EnableSync = true;
EnableSyncTranscoding = true;
EnableMediaPlayback = true;