Table of Contents

Class AniFrameMetadata

Namespace
SixLabors.ImageSharp.Formats.Ani
Assembly
SixLabors.ImageSharp.dll

Provides ANI-specific metadata for an image frame.

public class AniFrameMetadata : IFormatFrameMetadata<AniFrameMetadata>, IFormatFrameMetadata, IDeepCloneable, IDeepCloneable<AniFrameMetadata>
Inheritance
AniFrameMetadata
Implements
Inherited Members

Constructors

AniFrameMetadata()

Initializes a new instance of the AniFrameMetadata class.

public AniFrameMetadata()

Properties

BmpBitsPerPixel

Gets or sets the embedded bitmap bits per pixel.

public BmpBitsPerPixel BmpBitsPerPixel { get; set; }

Property Value

BmpBitsPerPixel

ColorTable

Gets or sets the embedded bitmap color table. The underlying pixel format is represented by Bgr24.

public ReadOnlyMemory<Color>? ColorTable { get; set; }

Property Value

ReadOnlyMemory<Color>?

Compression

Gets or sets the embedded ICO or CUR compression format.

public IconFrameCompression Compression { get; set; }

Property Value

IconFrameCompression

EncodingHeight

Gets or sets the encoded frame height. A value of zero represents 256 pixels or greater in ICO and CUR resources.

public byte? EncodingHeight { get; set; }

Property Value

byte?

EncodingWidth

Gets or sets the encoded frame width. A value of zero represents 256 pixels or greater in ICO and CUR resources.

public byte? EncodingWidth { get; set; }

Property Value

byte?

FrameDelay

Gets or sets the frame display time in sixtieths of a second.

public uint FrameDelay { get; set; }

Property Value

uint

FrameFormat

Gets or sets the format used for this frame resource.

public AniFrameFormat FrameFormat { get; set; }

Property Value

AniFrameFormat

HotspotX

Gets or sets the horizontal cursor hotspot in pixels from the left.

public ushort HotspotX { get; set; }

Property Value

ushort

HotspotY

Gets or sets the vertical cursor hotspot in pixels from the top.

public ushort HotspotY { get; set; }

Property Value

ushort

SequenceNumber

Gets or sets the animation sequence number. Adjacent frames with the same positive value are grouped as resolution variants in one ANI frame resource. A non-positive value encodes the frame as its own animation step.

public int SequenceNumber { get; set; }

Property Value

int

Methods

AfterFrameApply<TPixel>(ImageFrame<TPixel>, ImageFrame<TPixel>, Matrix4x4)

This method is called after a process has been applied to the image frame.

public void AfterFrameApply<TPixel>(ImageFrame<TPixel> source, ImageFrame<TPixel> destination, Matrix4x4 matrix) where TPixel : unmanaged, IPixel<TPixel>

Parameters

source ImageFrame<TPixel>

The source image frame.

destination ImageFrame<TPixel>

The destination image frame.

matrix Matrix4x4

The transformation matrix applied to the image frame.

Type Parameters

TPixel

The type of pixel format.

DeepClone()

Creates a new AniFrameMetadata that is a deep copy of the current instance.

public AniFrameMetadata DeepClone()

Returns

AniFrameMetadata

The AniFrameMetadata.

FromFormatConnectingFrameMetadata(FormatConnectingFrameMetadata)

Creates a new instance of the AniFrameMetadata class from the given FormatConnectingFrameMetadata.

public static AniFrameMetadata FromFormatConnectingFrameMetadata(FormatConnectingFrameMetadata metadata)

Parameters

metadata FormatConnectingFrameMetadata

The FormatConnectingFrameMetadata.

Returns

AniFrameMetadata

The AniFrameMetadata.

ToFormatConnectingFrameMetadata()

Converts the metadata to a FormatConnectingFrameMetadata instance.

public FormatConnectingFrameMetadata ToFormatConnectingFrameMetadata()

Returns

FormatConnectingFrameMetadata

The FormatConnectingFrameMetadata.