fix SA1513/SA1516

This commit is contained in:
telans
2020-06-16 09:43:52 +12:00
parent 25f8e596cb
commit 247f9c61e6
283 changed files with 1810 additions and 0 deletions

View File

@@ -125,6 +125,7 @@ namespace MediaBrowser.Model.Entities
{
attributes.Add(StringHelper.FirstToUpper(Language));
}
if (!string.IsNullOrEmpty(Codec) && !string.Equals(Codec, "dca", StringComparison.OrdinalIgnoreCase))
{
attributes.Add(AudioCodec.GetFriendlyName(Codec));
@@ -142,6 +143,7 @@ namespace MediaBrowser.Model.Entities
{
attributes.Add(Channels.Value.ToString(CultureInfo.InvariantCulture) + " ch");
}
if (IsDefault)
{
attributes.Add("Default");
@@ -227,30 +229,37 @@ namespace MediaBrowser.Model.Entities
{
return "4K";
}
if (width >= 2500)
{
if (i.IsInterlaced)
{
return "1440i";
}
return "1440p";
}
if (width >= 1900 || height >= 1000)
{
if (i.IsInterlaced)
{
return "1080i";
}
return "1080p";
}
if (width >= 1260 || height >= 700)
{
if (i.IsInterlaced)
{
return "720i";
}
return "720p";
}
if (width >= 700 || height >= 440)
{
@@ -258,11 +267,13 @@ namespace MediaBrowser.Model.Entities
{
return "480i";
}
return "480p";
}
return "SD";
}
return null;
}
@@ -448,6 +459,7 @@ namespace MediaBrowser.Model.Entities
{
return false;
}
if (string.Equals(fromCodec, "ssa", StringComparison.OrdinalIgnoreCase))
{
return false;
@@ -458,6 +470,7 @@ namespace MediaBrowser.Model.Entities
{
return false;
}
if (string.Equals(toCodec, "ssa", StringComparison.OrdinalIgnoreCase))
{
return false;