2019-01-13 13:02:23 -07:00
|
|
|
namespace MediaBrowser.Model.MediaInfo
|
2018-12-27 16:27:57 -07:00
|
|
|
{
|
|
|
|
public class AudioCodec
|
|
|
|
{
|
|
|
|
public const string AAC = "aac";
|
|
|
|
public const string MP3 = "mp3";
|
|
|
|
public const string AC3 = "ac3";
|
|
|
|
|
|
|
|
public static string GetFriendlyName(string codec)
|
|
|
|
{
|
2019-01-27 04:03:43 -07:00
|
|
|
if (string.IsNullOrEmpty(codec))
|
|
|
|
{
|
|
|
|
return string.Empty;
|
|
|
|
}
|
2018-12-27 16:27:57 -07:00
|
|
|
|
2019-01-27 04:03:43 -07:00
|
|
|
switch (codec.ToLowerInvariant())
|
2018-12-27 16:27:57 -07:00
|
|
|
{
|
|
|
|
case "ac3":
|
|
|
|
return "Dolby Digital";
|
|
|
|
case "eac3":
|
|
|
|
return "Dolby Digital+";
|
|
|
|
case "dca":
|
|
|
|
return "DTS";
|
|
|
|
default:
|
2019-01-27 04:03:43 -07:00
|
|
|
return codec.ToUpperInvariant();
|
2018-12-27 16:27:57 -07:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2019-01-13 12:31:15 -07:00
|
|
|
}
|