1
0
mirror of https://github.com/Radarr/Radarr.git synced 2026-04-23 22:25:14 -04:00

Added: Ability to add custom formats, working similar to qualities. (#2669)

Originally called project metis, this feature allows you to do a lot of cool stuff, such as upgrading to a x265 encode, downloading releases with multiple languages, etc. Check out the wiki page at: https://github.com/Radarr/Radarr/wiki/Custom-Formats to learn more! Note: This feature is currently in "beta" and will get more tags and features in the future. Please let me know, if you have any issues and I hope this will allow for a lot of customization!
This commit is contained in:
Leonardo Galli
2018-08-05 16:28:05 +02:00
committed by GitHub
parent d046a73f78
commit 77f146b262
272 changed files with 12585 additions and 4092 deletions
@@ -2,6 +2,7 @@ using System;
using System.Collections.Generic;
using System.IO;
using NLog;
using NzbDrone.Core.CustomFormats;
using NzbDrone.Core.MediaFiles.MediaInfo;
using NzbDrone.Core.Qualities;
using NzbDrone.Core.Movies;
@@ -18,7 +19,8 @@ namespace NzbDrone.Core.MediaFiles.MovieImport
private readonly IVideoFileInfoReader _videoFileInfoReader;
private readonly Logger _logger;
private static List<Quality> _largeSampleSizeQualities = new List<Quality> { Quality.HDTV1080p, Quality.WEBDL1080p, Quality.Bluray1080p };
//private static List<Quality> _largeSampleSizeQualities = new List<Quality> { Quality.HDTV1080p, Quality.WEBDL1080p, Quality.Bluray1080p };
private static List<Resolution> _largeSampleSizeResolutions = new List<Resolution>{Resolution.R1080P, Resolution.R2160P};
public DetectSample(IVideoFileInfoReader videoFileInfoReader, Logger logger)
{
@@ -81,7 +83,7 @@ namespace NzbDrone.Core.MediaFiles.MovieImport
private bool CheckSize(long size, QualityModel quality)
{
if (_largeSampleSizeQualities.Contains(quality.Quality))
if (_largeSampleSizeResolutions.Contains(quality.Resolution))
{
if (size < SampleSizeLimit * 2)
{