| | 1 | | using System; |
| | 2 | | using System.Collections.Generic; |
| | 3 | | using MediaBrowser.Controller.Drawing; |
| | 4 | | using MediaBrowser.Model.Drawing; |
| | 5 | |
|
| | 6 | | namespace Jellyfin.Drawing; |
| | 7 | |
|
| | 8 | | /// <summary> |
| | 9 | | /// A fallback implementation of <see cref="IImageEncoder" />. |
| | 10 | | /// </summary> |
| | 11 | | public class NullImageEncoder : IImageEncoder |
| | 12 | | { |
| | 13 | | /// <inheritdoc /> |
| | 14 | | public IReadOnlyCollection<string> SupportedInputFormats |
| 0 | 15 | | => new HashSet<string>(StringComparer.OrdinalIgnoreCase) { "png", "jpeg", "jpg" }; |
| | 16 | |
|
| | 17 | | /// <inheritdoc /> |
| | 18 | | public IReadOnlyCollection<ImageFormat> SupportedOutputFormats |
| 0 | 19 | | => new HashSet<ImageFormat>() { ImageFormat.Jpg, ImageFormat.Png }; |
| | 20 | |
|
| | 21 | | /// <inheritdoc /> |
| 0 | 22 | | public string Name => "Null Image Encoder"; |
| | 23 | |
|
| | 24 | | /// <inheritdoc /> |
| 0 | 25 | | public bool SupportsImageCollageCreation => false; |
| | 26 | |
|
| | 27 | | /// <inheritdoc /> |
| 0 | 28 | | public bool SupportsImageEncoding => false; |
| | 29 | |
|
| | 30 | | /// <inheritdoc /> |
| | 31 | | public ImageDimensions GetImageSize(string path) |
| 0 | 32 | | => throw new NotImplementedException(); |
| | 33 | |
|
| | 34 | | /// <inheritdoc /> |
| | 35 | | public string EncodeImage(string inputPath, DateTime dateModified, string outputPath, bool autoOrient, ImageOrientat |
| | 36 | | { |
| 0 | 37 | | throw new NotImplementedException(); |
| | 38 | | } |
| | 39 | |
|
| | 40 | | /// <inheritdoc /> |
| | 41 | | public void CreateImageCollage(ImageCollageOptions options, string? libraryName) |
| | 42 | | { |
| 0 | 43 | | throw new NotImplementedException(); |
| | 44 | | } |
| | 45 | |
|
| | 46 | | /// <inheritdoc /> |
| | 47 | | public void CreateSplashscreen(IReadOnlyList<string> posters, IReadOnlyList<string> backdrops) |
| | 48 | | { |
| 0 | 49 | | throw new NotImplementedException(); |
| | 50 | | } |
| | 51 | |
|
| | 52 | | /// <inheritdoc /> |
| | 53 | | public int CreateTrickplayTile(ImageCollageOptions options, int quality, int imgWidth, int? imgHeight) |
| | 54 | | { |
| 0 | 55 | | throw new NotImplementedException(); |
| | 56 | | } |
| | 57 | |
|
| | 58 | | /// <inheritdoc /> |
| | 59 | | public string GetImageBlurHash(int xComp, int yComp, string path) |
| | 60 | | { |
| 0 | 61 | | throw new NotImplementedException(); |
| | 62 | | } |
| | 63 | | } |