diff options
Diffstat (limited to 'Emby.Drawing.ImageMagick/ImageMagickEncoder.cs')
| -rw-r--r-- | Emby.Drawing.ImageMagick/ImageMagickEncoder.cs | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/Emby.Drawing.ImageMagick/ImageMagickEncoder.cs b/Emby.Drawing.ImageMagick/ImageMagickEncoder.cs index ea8687de0..2c40bf570 100644 --- a/Emby.Drawing.ImageMagick/ImageMagickEncoder.cs +++ b/Emby.Drawing.ImageMagick/ImageMagickEncoder.cs @@ -7,13 +7,12 @@ using MediaBrowser.Model.Drawing; using MediaBrowser.Model.Logging; using System; using System.IO; -using System.Linq; using MediaBrowser.Model.IO; using MediaBrowser.Model.System; namespace Emby.Drawing.ImageMagick { - public class ImageMagickEncoder : IImageEncoder + public class ImageMagickEncoder : IImageEncoder, IDisposable { private readonly ILogger _logger; private readonly IApplicationPaths _appPaths; @@ -39,7 +38,8 @@ namespace Emby.Drawing.ImageMagick // Some common file name extensions for RAW picture files include: .cr2, .crw, .dng, .nef, .orf, .rw2, .pef, .arw, .sr2, .srf, and .tif. return new[] { - "tiff", + "tiff", + "tif", "jpeg", "jpg", "png", @@ -306,15 +306,15 @@ namespace Emby.Drawing.ImageMagick if (ratio >= 1.4) { - new StripCollageBuilder(_appPaths, _fileSystem).BuildThumbCollage(options.InputPaths.ToList(), options.OutputPath, options.Width, options.Height); + new StripCollageBuilder(_appPaths, _fileSystem).BuildThumbCollage(options.InputPaths, options.OutputPath, options.Width, options.Height); } else if (ratio >= .9) { - new StripCollageBuilder(_appPaths, _fileSystem).BuildSquareCollage(options.InputPaths.ToList(), options.OutputPath, options.Width, options.Height); + new StripCollageBuilder(_appPaths, _fileSystem).BuildSquareCollage(options.InputPaths, options.OutputPath, options.Width, options.Height); } else { - new StripCollageBuilder(_appPaths, _fileSystem).BuildPosterCollage(options.InputPaths.ToList(), options.OutputPath, options.Width, options.Height); + new StripCollageBuilder(_appPaths, _fileSystem).BuildPosterCollage(options.InputPaths, options.OutputPath, options.Width, options.Height); } } @@ -328,6 +328,7 @@ namespace Emby.Drawing.ImageMagick { _disposed = true; Wand.CloseEnvironment(); + GC.SuppressFinalize(this); } private void CheckDisposed() |
