diff options
| author | Luke <luke.pulverenti@gmail.com> | 2017-05-04 15:05:22 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2017-05-04 15:05:22 -0400 |
| commit | 6e53aa0e076c2ce2bd7b1a462196b099c77f90e5 (patch) | |
| tree | 0fb73d80406fffe26b77c40c288389a291ddd3af /MediaBrowser.MediaEncoding/Encoder/MediaEncoder.cs | |
| parent | fb74ee3bb616f7532c79bec0113a14fec3a65be1 (diff) | |
| parent | 364c8206bf500ac466d5360ddfe01b67fa8b59a9 (diff) | |
Merge pull request #2613 from MediaBrowser/dev
Dev
Diffstat (limited to 'MediaBrowser.MediaEncoding/Encoder/MediaEncoder.cs')
| -rw-r--r-- | MediaBrowser.MediaEncoding/Encoder/MediaEncoder.cs | 21 |
1 files changed, 4 insertions, 17 deletions
diff --git a/MediaBrowser.MediaEncoding/Encoder/MediaEncoder.cs b/MediaBrowser.MediaEncoding/Encoder/MediaEncoder.cs index 130afa3e3..c58a18b0f 100644 --- a/MediaBrowser.MediaEncoding/Encoder/MediaEncoder.cs +++ b/MediaBrowser.MediaEncoding/Encoder/MediaEncoder.cs @@ -187,18 +187,6 @@ namespace MediaBrowser.MediaEncoding.Encoder } } - public bool IsDefaultEncoderPath - { - get - { - var path = FFMpegPath; - - var parentPath = Path.Combine(ConfigurationManager.ApplicationPaths.ProgramDataPath, "ffmpeg", "20160410"); - - return FileSystem.ContainsSubPath(parentPath, path); - } - } - private bool IsSystemInstalledPath(string path) { if (path.IndexOf("/", StringComparison.Ordinal) == -1 && path.IndexOf("\\", StringComparison.Ordinal) == -1) @@ -222,12 +210,11 @@ namespace MediaBrowser.MediaEncoding.Encoder if (EnableEncoderFontFile) { - var directory = Path.GetDirectoryName(FFMpegPath); + var directory = FileSystem.GetDirectoryName(FFMpegPath); if (!string.IsNullOrWhiteSpace(directory) && FileSystem.ContainsSubPath(ConfigurationManager.ApplicationPaths.ProgramDataPath, directory)) { - await new FontConfigLoader(_httpClient, ConfigurationManager.ApplicationPaths, _logger, _zipClient, - FileSystem).DownloadFonts(directory).ConfigureAwait(false); + await new FontConfigLoader(_httpClient, ConfigurationManager.ApplicationPaths, _logger, _zipClient, FileSystem).DownloadFonts(directory).ConfigureAwait(false); } } } @@ -428,7 +415,7 @@ namespace MediaBrowser.MediaEncoding.Encoder private string GetProbePathFromEncoderPath(string appPath) { - return FileSystem.GetFilePaths(Path.GetDirectoryName(appPath)) + return FileSystem.GetFilePaths(FileSystem.GetDirectoryName(appPath)) .FirstOrDefault(i => string.Equals(Path.GetFileNameWithoutExtension(i), "ffprobe", StringComparison.OrdinalIgnoreCase)); } @@ -717,7 +704,7 @@ namespace MediaBrowser.MediaEncoding.Encoder } var tempExtractPath = Path.Combine(ConfigurationManager.ApplicationPaths.TempDirectory, Guid.NewGuid() + ".jpg"); - FileSystem.CreateDirectory(Path.GetDirectoryName(tempExtractPath)); + FileSystem.CreateDirectory(FileSystem.GetDirectoryName(tempExtractPath)); // apply some filters to thumbnail extracted below (below) crop any black lines that we made and get the correct ar then scale to width 600. // This filter chain may have adverse effects on recorded tv thumbnails if ar changes during presentation ex. commercials @ diff ar |
