mirror of
https://github.com/jellyfin/jellyfin.git
synced 2025-12-24 01:34:45 +03:00
extracted a media encoding interface to keep ffmpeg out of nuget packages
This commit is contained in:
@@ -23,7 +23,7 @@ namespace MediaBrowser.Controller.Drawing
|
||||
/// <summary>
|
||||
/// Class ImageManager
|
||||
/// </summary>
|
||||
public class ImageManager : IDisposable
|
||||
public class ImageManager
|
||||
{
|
||||
/// <summary>
|
||||
/// Gets the image size cache.
|
||||
@@ -681,28 +681,5 @@ namespace MediaBrowser.Controller.Drawing
|
||||
{
|
||||
return _locks.GetOrAdd(filename, key => new SemaphoreSlim(1, 1));
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
|
||||
/// </summary>
|
||||
public void Dispose()
|
||||
{
|
||||
Dispose(true);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Releases unmanaged and - optionally - managed resources.
|
||||
/// </summary>
|
||||
/// <param name="dispose"><c>true</c> to release both managed and unmanaged resources; <c>false</c> to release only unmanaged resources.</param>
|
||||
protected void Dispose(bool dispose)
|
||||
{
|
||||
if (dispose)
|
||||
{
|
||||
ImageSizeCache.Dispose();
|
||||
ResizedImageCache.Dispose();
|
||||
CroppedImageCache.Dispose();
|
||||
EnhancedImageCache.Dispose();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user