aboutsummaryrefslogtreecommitdiff
path: root/Emby.Drawing/ImageProcessor.cs
diff options
context:
space:
mode:
authorLuke <luke.pulverenti@gmail.com>2017-05-14 15:31:23 -0400
committerGitHub <noreply@github.com>2017-05-14 15:31:23 -0400
commitfcf588ac14333442e601559eed0d0991202611a4 (patch)
tree66029d07b31d7a418ed0a85f9177457b89bcb7ca /Emby.Drawing/ImageProcessor.cs
parent43d91a392fa2a4b5e41c240f2b6fc4082f6a73f9 (diff)
parentbdc546ed85dfb8389184234ac74c6cc7b4046515 (diff)
Merge pull request #2636 from MediaBrowser/dev
Dev
Diffstat (limited to 'Emby.Drawing/ImageProcessor.cs')
-rw-r--r--Emby.Drawing/ImageProcessor.cs25
1 files changed, 15 insertions, 10 deletions
diff --git a/Emby.Drawing/ImageProcessor.cs b/Emby.Drawing/ImageProcessor.cs
index 82181238b..ad6ca7d70 100644
--- a/Emby.Drawing/ImageProcessor.cs
+++ b/Emby.Drawing/ImageProcessor.cs
@@ -513,20 +513,25 @@ namespace Emby.Drawing
/// <returns>ImageSize.</returns>
private ImageSize GetImageSizeInternal(string path, bool allowSlowMethod)
{
- // Can't use taglib because it keeps a lock on the file
//try
//{
- // using (var file = TagLib.File.Create(new StreamFileAbstraction(Path.GetFileName(path), _fileSystem.OpenRead(path), null)))
+ // using (var fileStream = _fileSystem.OpenRead(path))
// {
- // var image = file as TagLib.Image.File;
-
- // var properties = image.Properties;
-
- // return new ImageSize
+ // using (var file = TagLib.File.Create(new StreamFileAbstraction(Path.GetFileName(path), fileStream, null)))
// {
- // Height = properties.PhotoHeight,
- // Width = properties.PhotoWidth
- // };
+ // var image = file as TagLib.Image.File;
+
+ // if (image != null)
+ // {
+ // var properties = image.Properties;
+
+ // return new ImageSize
+ // {
+ // Height = properties.PhotoHeight,
+ // Width = properties.PhotoWidth
+ // };
+ // }
+ // }
// }
//}
//catch