diff options
| author | Luke <luke.pulverenti@gmail.com> | 2017-04-23 17:25:32 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2017-04-23 17:25:32 -0400 |
| commit | a0dc26b88172f10efa6dbf0ff6c3dffd9733d097 (patch) | |
| tree | 9596ee46fcd9072a582c20a76c3090ddf6bfe723 /MediaBrowser.Server.Startup.Common | |
| parent | 82b86449cb4083ab8d875b22f40beb93d2f821f8 (diff) | |
| parent | c34ff57e1c188e3eda57a626077e804b36665dff (diff) | |
Merge pull request #2594 from MediaBrowser/dev
Dev
Diffstat (limited to 'MediaBrowser.Server.Startup.Common')
| -rw-r--r-- | MediaBrowser.Server.Startup.Common/ImageEncoderHelper.cs | 48 | ||||
| -rw-r--r-- | MediaBrowser.Server.Startup.Common/MediaBrowser.Server.Startup.Common.csproj | 13 |
2 files changed, 0 insertions, 61 deletions
diff --git a/MediaBrowser.Server.Startup.Common/ImageEncoderHelper.cs b/MediaBrowser.Server.Startup.Common/ImageEncoderHelper.cs deleted file mode 100644 index ddbde2f66..000000000 --- a/MediaBrowser.Server.Startup.Common/ImageEncoderHelper.cs +++ /dev/null @@ -1,48 +0,0 @@ -using System; -using Emby.Drawing; -using Emby.Drawing.Net; -using Emby.Drawing.ImageMagick; -using Emby.Server.Core; -using Emby.Server.Implementations; -using MediaBrowser.Common.Configuration; -using MediaBrowser.Common.Net; -using MediaBrowser.Controller.Drawing; -using MediaBrowser.Model.IO; -using MediaBrowser.Model.Logging; - -namespace MediaBrowser.Server.Startup.Common -{ - public class ImageEncoderHelper - { - public static IImageEncoder GetImageEncoder(ILogger logger, - ILogManager logManager, - IFileSystem fileSystem, - StartupOptions startupOptions, - Func<IHttpClient> httpClient, - IApplicationPaths appPaths) - { - if (!startupOptions.ContainsOption("-enablegdi")) - { - try - { - return new ImageMagickEncoder(logManager.GetLogger("ImageMagick"), appPaths, httpClient, fileSystem); - } - catch - { - logger.Error("Error loading ImageMagick. Will revert to GDI."); - } - } - - try - { - return new GDIImageEncoder(fileSystem, logManager.GetLogger("GDI")); - } - catch - { - logger.Error("Error loading GDI. Will revert to NullImageEncoder."); - } - - return new NullImageEncoder(); - } - } -} diff --git a/MediaBrowser.Server.Startup.Common/MediaBrowser.Server.Startup.Common.csproj b/MediaBrowser.Server.Startup.Common/MediaBrowser.Server.Startup.Common.csproj index 5eb492166..9a6cc2d6e 100644 --- a/MediaBrowser.Server.Startup.Common/MediaBrowser.Server.Startup.Common.csproj +++ b/MediaBrowser.Server.Startup.Common/MediaBrowser.Server.Startup.Common.csproj @@ -73,25 +73,12 @@ <Compile Include="Cryptography\X509Extension.cs" /> <Compile Include="Cryptography\X509Extensions.cs" /> <Compile Include="Cryptography\X520Attributes.cs" /> - <Compile Include="ImageEncoderHelper.cs" /> <Compile Include="IO\MemoryStreamProvider.cs" /> <Compile Include="Properties\AssemblyInfo.cs" /> <Compile Include="SystemEvents.cs" /> <Compile Include="UpdateLevelHelper.cs" /> </ItemGroup> <ItemGroup> - <ProjectReference Include="..\Emby.Drawing.ImageMagick\Emby.Drawing.ImageMagick.csproj"> - <Project>{6cfee013-6e7c-432b-ac37-cabf0880c69a}</Project> - <Name>Emby.Drawing.ImageMagick</Name> - </ProjectReference> - <ProjectReference Include="..\Emby.Drawing.Net\Emby.Drawing.Net.csproj"> - <Project>{c97a239e-a96c-4d64-a844-ccf8cc30aecb}</Project> - <Name>Emby.Drawing.Net</Name> - </ProjectReference> - <ProjectReference Include="..\Emby.Drawing\Emby.Drawing.csproj"> - <Project>{08fff49b-f175-4807-a2b5-73b0ebd9f716}</Project> - <Name>Emby.Drawing</Name> - </ProjectReference> <ProjectReference Include="..\Emby.Server.Implementations\Emby.Server.Implementations.csproj"> <Project>{e383961b-9356-4d5d-8233-9a1079d03055}</Project> <Name>Emby.Server.Implementations</Name> |
