Class ImageFrame
- Namespace
- SixLabors.ImageSharp
- Assembly
- SixLabors.ImageSharp.dll
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.
public abstract class ImageFrame : IConfigurationProvider, IDisposable
- Inheritance
-
ImageFrame
- Implements
- Derived
- Inherited Members
- Extension Methods
Constructors
ImageFrame(Configuration, int, int, ImageFrameMetadata)
Initializes a new instance of the ImageFrame class.
protected ImageFrame(Configuration configuration, int width, int height, ImageFrameMetadata metadata)
Parameters
configurationConfigurationThe configuration which allows altering default behaviour or extending the library.
widthintThe frame width.
heightintThe frame height.
metadataImageFrameMetadataThe ImageFrameMetadata.
Properties
Bounds
Gets the bounds of the frame.
public Rectangle Bounds { get; }
Property Value
Configuration
Gets the configuration which allows altering default behaviour or extending the library.
public Configuration Configuration { get; }
Property Value
Height
Gets the frame height in px units.
public int Height { get; }
Property Value
Metadata
Gets the metadata of the frame.
public ImageFrameMetadata Metadata { get; }
Property Value
Size
Gets the size of the frame.
public Size Size { get; }
Property Value
Width
Gets the frame width in px units.
public int Width { get; }
Property Value
Methods
Dispose()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
public void Dispose()
Dispose(bool)
Disposes the object and frees resources for the Garbage Collector.
protected abstract void Dispose(bool disposing)
Parameters
disposingboolWhether to dispose of managed and unmanaged objects.
UpdateMetadata(ImageFrameMetadata)
Updates the metadata of the image frame after mutation.
protected void UpdateMetadata(ImageFrameMetadata metadata)
Parameters
metadataImageFrameMetadataThe Metadata.
UpdateSize(Size)
Updates the size of the image frame after mutation.
protected void UpdateSize(Size size)