|
|
|
@ -34,27 +34,33 @@ namespace NzbDrone.Core.MediaFiles.MediaInfo
|
|
|
|
|
{
|
|
|
|
|
get
|
|
|
|
|
{
|
|
|
|
|
if (AudioChannelPositions.IsNullOrWhiteSpace())
|
|
|
|
|
{
|
|
|
|
|
if (AudioChannelPositionsText.IsNullOrWhiteSpace())
|
|
|
|
|
{
|
|
|
|
|
if (SchemaRevision >= 3)
|
|
|
|
|
{
|
|
|
|
|
return AudioChannels;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return 0;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return AudioChannelPositionsText.ContainsIgnoreCase("LFE") ? AudioChannels - 1 + 0.1m : AudioChannels;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return
|
|
|
|
|
AudioChannelPositions.Replace("Object Based /", "").Replace(" / ", "$")
|
|
|
|
|
.Split('$')
|
|
|
|
|
.First()
|
|
|
|
|
.Split('/')
|
|
|
|
|
.Sum(s => decimal.Parse(s, CultureInfo.InvariantCulture));
|
|
|
|
|
try
|
|
|
|
|
{
|
|
|
|
|
return
|
|
|
|
|
AudioChannelPositions.Replace("Object Based /", "").Replace(" / ", "$")
|
|
|
|
|
.Split('$')
|
|
|
|
|
.First()
|
|
|
|
|
.Split('/')
|
|
|
|
|
.Sum(s => decimal.Parse(s, CultureInfo.InvariantCulture));
|
|
|
|
|
}
|
|
|
|
|
catch
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
if (AudioChannelPositionsText.IsNullOrWhiteSpace())
|
|
|
|
|
{
|
|
|
|
|
if (SchemaRevision >= 3)
|
|
|
|
|
{
|
|
|
|
|
return AudioChannels;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return 0;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return AudioChannelPositionsText.ContainsIgnoreCase("LFE") ? AudioChannels - 1 + 0.1m : AudioChannels;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|