|
|
@ -96,12 +96,32 @@ namespace NzbDrone.Core.MediaFiles.MediaInfo
|
|
|
|
return "MP3";
|
|
|
|
return "MP3";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if (mediaInfo.AudioProfile == "Layer 2")
|
|
|
|
if (mediaInfo.AudioCodecID == "A_MPEG/L2" || mediaInfo.AudioProfile == "Layer 2")
|
|
|
|
{
|
|
|
|
{
|
|
|
|
return "MP2";
|
|
|
|
return "MP2";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (audioFormat.EqualsIgnoreCase("PCM"))
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return "PCM";
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (audioFormat.EqualsIgnoreCase("TrueHD"))
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return "TrueHD";
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (audioFormat.EqualsIgnoreCase("Vorbis"))
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return "Vorbis";
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (audioFormat == "WMA")
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return "WMA";
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
Logger.Debug()
|
|
|
|
Logger.Debug()
|
|
|
|
.Message("Unknown audio format: '{0}' in '{1}'.", string.Join(", ", audioFormat, audioCodecID, audioProfile, audioCodecLibrary), sceneName)
|
|
|
|
.Message("Unknown audio format: '{0}' in '{1}'.", string.Join(", ", audioFormat, audioCodecID, audioProfile, audioCodecLibrary), sceneName)
|
|
|
|
.WriteSentryWarn("UnknownAudioFormat", mediaInfo.ContainerFormat, audioFormat, audioCodecID)
|
|
|
|
.WriteSentryWarn("UnknownAudioFormat", mediaInfo.ContainerFormat, audioFormat, audioCodecID)
|
|
|
@ -184,7 +204,7 @@ namespace NzbDrone.Core.MediaFiles.MediaInfo
|
|
|
|
return videoFormat;
|
|
|
|
return videoFormat;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if (videoFormat == "AVC")
|
|
|
|
if (videoFormat == "AVC" || videoFormat == "V.MPEG4/ISO/AVC")
|
|
|
|
{
|
|
|
|
{
|
|
|
|
if (videoCodecLibrary.StartsWithIgnoreCase("x264"))
|
|
|
|
if (videoCodecLibrary.StartsWithIgnoreCase("x264"))
|
|
|
|
{
|
|
|
|
{
|
|
|
@ -194,6 +214,11 @@ namespace NzbDrone.Core.MediaFiles.MediaInfo
|
|
|
|
return GetSceneNameMatch(sceneName, "AVC", "h264");
|
|
|
|
return GetSceneNameMatch(sceneName, "AVC", "h264");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (videoFormat.EqualsIgnoreCase("DivX"))
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return "DivX";
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if (videoFormat == "HEVC")
|
|
|
|
if (videoFormat == "HEVC")
|
|
|
|
{
|
|
|
|
{
|
|
|
|
if (videoCodecLibrary.StartsWithIgnoreCase("x265"))
|
|
|
|
if (videoCodecLibrary.StartsWithIgnoreCase("x265"))
|
|
|
@ -204,6 +229,19 @@ namespace NzbDrone.Core.MediaFiles.MediaInfo
|
|
|
|
return GetSceneNameMatch(sceneName, "HEVC", "h265");
|
|
|
|
return GetSceneNameMatch(sceneName, "HEVC", "h265");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (videoFormat == "MPEG Video")
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
if (videoCodecID == "2" || videoCodecID == "V_MPEG2")
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return "MPEG2";
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (videoCodecID.IsNullOrWhiteSpace())
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return "MPEG";
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if (videoFormat == "MPEG-2 Video")
|
|
|
|
if (videoFormat == "MPEG-2 Video")
|
|
|
|
{
|
|
|
|
{
|
|
|
|
return "MPEG2";
|
|
|
|
return "MPEG2";
|
|
|
@ -224,6 +262,21 @@ namespace NzbDrone.Core.MediaFiles.MediaInfo
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (videoFormat == "VC-1")
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return "VC1";
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (videoFormat == "WMV2")
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return "WMV";
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (videoFormat.EqualsIgnoreCase("XviD"))
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return "XviD";
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
Logger.Debug()
|
|
|
|
Logger.Debug()
|
|
|
|
.Message("Unknown video format: '{0}' in '{1}'.", string.Join(", ", videoFormat, videoCodecID, videoProfile, videoCodecLibrary), sceneName)
|
|
|
|
.Message("Unknown video format: '{0}' in '{1}'.", string.Join(", ", videoFormat, videoCodecID, videoProfile, videoCodecLibrary), sceneName)
|
|
|
|
.WriteSentryWarn("UnknownVideoFormat", mediaInfo.ContainerFormat, videoFormat, videoCodecID)
|
|
|
|
.WriteSentryWarn("UnknownVideoFormat", mediaInfo.ContainerFormat, videoFormat, videoCodecID)
|
|
|
|