Skip to content

Commit

Permalink
manual port of 3.1 gif decoder
Browse files Browse the repository at this point in the history
  • Loading branch information
antonfirsov committed Jul 12, 2024
1 parent 28c20de commit 3bf8c57
Show file tree
Hide file tree
Showing 5 changed files with 527 additions and 334 deletions.
5 changes: 5 additions & 0 deletions src/ImageSharp/Formats/Gif/GifDecoder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,11 @@ public sealed class GifDecoder : IImageDecoder, IGifDecoderOptions, IImageInfoDe
/// </summary>
public FrameDecodingMode DecodingMode { get; set; } = FrameDecodingMode.All;

/// <summary>
/// Gets or sets the maximum number of gif frames.
/// </summary>
public uint MaxFrames { get; set; } = uint.MaxValue;

/// <inheritdoc/>
public Image<TPixel> Decode<TPixel>(Configuration configuration, Stream stream, CancellationToken cancellationToken)
where TPixel : unmanaged, IPixel<TPixel>
Expand Down
Loading

0 comments on commit 3bf8c57

Please sign in to comment.