Class AffineTransformProcessor
Defines an affine transformation applicable on an Image.
Inherited Members
Namespace: SixLabors.ImageSharp.Processing.Processors.Transforms
Assembly: SixLabors.ImageSharp.dll
Syntax
public class AffineTransformProcessor : CloningImageProcessor, ICloningImageProcessor, IImageProcessor
Constructors
| Edit this page View SourceAffineTransformProcessor(Matrix3x2, IResampler, Size)
Initializes a new instance of the AffineTransformProcessor class.
Declaration
public AffineTransformProcessor(Matrix3x2 matrix, IResampler sampler, Size targetDimensions)
Parameters
Type | Name | Description |
---|---|---|
Matrix3x2 | matrix | The transform matrix. |
IResampler | sampler | The sampler to perform the transform operation. |
Size | targetDimensions | The target dimensions. |
Properties
| Edit this page View SourceDestinationSize
Gets the destination size to constrain the transformed image to.
Declaration
public Size DestinationSize { get; }
Property Value
Type | Description |
---|---|
Size |
Sampler
Gets the sampler to perform interpolation of the transform operation.
Declaration
public IResampler Sampler { get; }
Property Value
Type | Description |
---|---|
IResampler |
TransformMatrix
Gets the matrix used to supply the affine transform.
Declaration
public Matrix3x2 TransformMatrix { get; }
Property Value
Type | Description |
---|---|
Matrix3x2 |
Methods
| Edit this page View SourceCreatePixelSpecificCloningProcessor<TPixel>(Configuration, Image<TPixel>, Rectangle)
Creates a pixel specific ICloningImageProcessor<TPixel> that is capable of executing the processing algorithm on an Image<TPixel>.
Declaration
public override ICloningImageProcessor<TPixel> CreatePixelSpecificCloningProcessor<TPixel>(Configuration configuration, Image<TPixel> source, Rectangle sourceRectangle) where TPixel : unmanaged, IPixel<TPixel>
Parameters
Type | Name | Description |
---|---|---|
Configuration | configuration | The configuration which allows altering default behaviour or extending the library. |
Image<TPixel> | source | The source image. Cannot be null. |
Rectangle | sourceRectangle | The Rectangle structure that specifies the portion of the image object to draw. |
Returns
Type | Description |
---|---|
ICloningImageProcessor<TPixel> |
Type Parameters
Name | Description |
---|---|
TPixel | The pixel type. |