Table of Contents

Class ImageBrush<TPixel>

Namespace
SixLabors.ImageSharp.Drawing.Processing
Assembly
SixLabors.ImageSharp.Drawing.dll

Provides an implementation of an image brush for painting images within areas.

public sealed class ImageBrush<TPixel> : ImageBrush, IEquatable<Brush> where TPixel : unmanaged, IPixel<TPixel>

Type Parameters

TPixel

The pixel format of the source image.

Inheritance
ImageBrush<TPixel>
Implements
Inherited Members

Constructors

ImageBrush(Image<TPixel>)

Initializes a new instance of the ImageBrush<TPixel> class.

public ImageBrush(Image<TPixel> image)

Parameters

image Image<TPixel>

The source image to draw.

ImageBrush(Image<TPixel>, Point)

Initializes a new instance of the ImageBrush<TPixel> class.

public ImageBrush(Image<TPixel> image, Point offset)

Parameters

image Image<TPixel>

The source image to draw.

offset Point

An offset to apply to the image while drawing the texture.

ImageBrush(Image<TPixel>, RectangleF)

Initializes a new instance of the ImageBrush<TPixel> class.

public ImageBrush(Image<TPixel> image, RectangleF region)

Parameters

image Image<TPixel>

The source image to draw.

region RectangleF

The region of interest within the source image.

ImageBrush(Image<TPixel>, RectangleF, Point)

Initializes a new instance of the ImageBrush<TPixel> class.

public ImageBrush(Image<TPixel> image, RectangleF region, Point offset)

Parameters

image Image<TPixel>

The source image to draw.

region RectangleF

The region of interest within the source image.

offset Point

An offset to apply to the image while drawing the texture.

Properties

SourceImage

Gets the typed source image used by this brush.

public Image<TPixel> SourceImage { get; }

Property Value

Image<TPixel>