support max audio bit depth

This commit is contained in:
Luke Pulverenti
2017-06-26 11:10:52 -04:00
parent c2c1451beb
commit a759b09577
14 changed files with 90 additions and 18 deletions

View File

@@ -12,7 +12,7 @@ namespace MediaBrowser.Model.Dlna
public bool IsVideoConditionSatisfied(ProfileCondition condition,
int? width,
int? height,
int? bitDepth,
int? videoBitDepth,
int? videoBitrate,
string videoProfile,
double? videoLevel,
@@ -46,7 +46,7 @@ namespace MediaBrowser.Model.Dlna
case ProfileConditionValue.PacketLength:
return IsConditionSatisfied(condition, packetLength);
case ProfileConditionValue.VideoBitDepth:
return IsConditionSatisfied(condition, bitDepth);
return IsConditionSatisfied(condition, videoBitDepth);
case ProfileConditionValue.VideoBitrate:
return IsConditionSatisfied(condition, videoBitrate);
case ProfileConditionValue.Height:
@@ -79,7 +79,7 @@ namespace MediaBrowser.Model.Dlna
}
}
public bool IsAudioConditionSatisfied(ProfileCondition condition, int? audioChannels, int? audioBitrate, int? audioSampleRate)
public bool IsAudioConditionSatisfied(ProfileCondition condition, int? audioChannels, int? audioBitrate, int? audioSampleRate, int? audioBitDepth)
{
switch (condition.Property)
{
@@ -89,6 +89,8 @@ namespace MediaBrowser.Model.Dlna
return IsConditionSatisfied(condition, audioChannels);
case ProfileConditionValue.AudioSampleRate:
return IsConditionSatisfied(condition, audioSampleRate);
case ProfileConditionValue.AudioBitDepth:
return IsConditionSatisfied(condition, audioBitDepth);
default:
throw new ArgumentException("Unexpected condition on audio file: " + condition.Property);
}
@@ -97,7 +99,8 @@ namespace MediaBrowser.Model.Dlna
public bool IsVideoAudioConditionSatisfied(ProfileCondition condition,
int? audioChannels,
int? audioBitrate,
int? audioSampleRate,
int? audioSampleRate,
int? audioBitDepth,
string audioProfile,
bool? isSecondaryTrack)
{
@@ -113,6 +116,8 @@ namespace MediaBrowser.Model.Dlna
return IsConditionSatisfied(condition, isSecondaryTrack);
case ProfileConditionValue.AudioSampleRate:
return IsConditionSatisfied(condition, audioSampleRate);
case ProfileConditionValue.AudioBitDepth:
return IsConditionSatisfied(condition, audioBitDepth);
default:
throw new ArgumentException("Unexpected condition on audio file: " + condition.Property);
}