mirror of
https://github.com/jellyfin/jellyfin.git
synced 2024-11-16 10:29:01 -07:00
07cc4be6a7
* Add analyzers to MediaBrowser.XbmcMetadata * Enable TreatWarningsAsErrors for MediaBrowser.XbmcMetadata * Add analyzers to MediaBrowser.WebDashboard * Enable TreatWarningsAsErrors for MediaBrowser.WebDashboard * Disable SA1600 in favor of CS1591
32 lines
796 B
C#
32 lines
796 B
C#
#pragma warning disable CS1591
|
|
|
|
namespace MediaBrowser.Model.MediaInfo
|
|
{
|
|
public static class AudioCodec
|
|
{
|
|
public const string AAC = "aac";
|
|
public const string MP3 = "mp3";
|
|
public const string AC3 = "ac3";
|
|
|
|
public static string GetFriendlyName(string codec)
|
|
{
|
|
if (string.IsNullOrEmpty(codec))
|
|
{
|
|
return string.Empty;
|
|
}
|
|
|
|
switch (codec.ToLowerInvariant())
|
|
{
|
|
case "ac3":
|
|
return "Dolby Digital";
|
|
case "eac3":
|
|
return "Dolby Digital+";
|
|
case "dca":
|
|
return "DTS";
|
|
default:
|
|
return codec.ToUpperInvariant();
|
|
}
|
|
}
|
|
}
|
|
}
|