Class ImageFrame
Represents a pixel-agnostic image frame containing all pixel data and ImageFrameMetadata. In case of animated formats like gif, it contains the single frame in a animation. In all other cases it is the only frame of the image.
Implements
Inherited Members
Namespace: SixLabors.ImageSharp
Assembly: SixLabors.ImageSharp.dll
Syntax
public abstract class ImageFrame : IDisposableConstructors
| Improve this Doc View SourceImageFrame(Configuration, Int32, Int32, ImageFrameMetadata)
Initializes a new instance of the ImageFrame class.
Declaration
protected ImageFrame(Configuration configuration, int width, int height, ImageFrameMetadata metadata)Parameters
| Type | Name | Description | 
|---|---|---|
| Configuration | configuration | The configuration which allows altering default behaviour or extending the library. | 
| Int32 | width | The frame width. | 
| Int32 | height | The frame height. | 
| ImageFrameMetadata | metadata | The ImageFrameMetadata. | 
Properties
| Improve this Doc View SourceHeight
Gets the height.
Declaration
public int Height { get; }Property Value
| Type | Description | 
|---|---|
| Int32 | 
Metadata
Gets the metadata of the frame.
Declaration
public ImageFrameMetadata Metadata { get; }Property Value
| Type | Description | 
|---|---|
| ImageFrameMetadata | 
Width
Gets the width.
Declaration
public int Width { get; }Property Value
| Type | Description | 
|---|---|
| Int32 | 
Methods
| Improve this Doc View SourceBounds()
Gets the bounds of the frame.
Declaration
public Rectangle Bounds()Returns
| Type | Description | 
|---|---|
| Rectangle | The Rectangle | 
Dispose()
Declaration
public void Dispose()Dispose(Boolean)
Disposes the object and frees resources for the Garbage Collector.
Declaration
protected abstract void Dispose(bool disposing)Parameters
| Type | Name | Description | 
|---|---|---|
| Boolean | disposing | Whether to dispose of managed and unmanaged objects. | 
Size()
Gets the size of the frame.
Declaration
public Size Size()Returns
| Type | Description | 
|---|---|
| Size | The Size() |