Struct TriangleResampler
- Namespace
- SixLabors.ImageSharp.Processing.Processors.Transforms
- Assembly
- SixLabors.ImageSharp.dll
The function implements the triangle (bilinear) algorithm. Bilinear interpolation can be used where perfect image transformation with pixel matching is impossible, so that one can calculate and assign appropriate intensity values to pixels.
public readonly struct TriangleResampler : IResampler
- Implements
- Inherited Members
Properties
Radius
Gets the radius in which to sample pixels.
public float Radius { get; }
Property Value
Methods
ApplyTransform<TPixel>(IResamplingTransformImageProcessor<TPixel>)
Applies a transformation upon an image.
public void ApplyTransform<TPixel>(IResamplingTransformImageProcessor<TPixel> processor) where TPixel : unmanaged, IPixel<TPixel>
Parameters
processorIResamplingTransformImageProcessor<TPixel>The transforming image processor.
Type Parameters
TPixelThe pixel format.
GetValue(float)
Gets the result of the interpolation algorithm.
public float GetValue(float x)
Parameters
xfloatThe value to process.