mirror of https://github.com/SixLabors/ImageSharp
Browse Source
Former-commit-id: 6c024e150c3521c9a8f6ac12da96abfd7b4d1be7 Former-commit-id: 598e6e70606a95d16c6205d4eb04a960842246aa Former-commit-id: 2c3e00cf2db86aaf7eedcbca3b7eef382d689885af/merge-core
20 changed files with 106 additions and 102 deletions
@ -1,26 +0,0 @@ |
|||
// <copyright file="RobidouxSoftResampler.cs" company="James Jackson-South">
|
|||
// Copyright (c) James Jackson-South and contributors.
|
|||
// Licensed under the Apache License, Version 2.0.
|
|||
// </copyright>
|
|||
|
|||
namespace ImageProcessorCore |
|||
{ |
|||
/// <summary>
|
|||
/// The function implements the Robidoux Soft algorithm.
|
|||
/// <see href="http://www.imagemagick.org/Usage/filter/#robidoux"/>
|
|||
/// </summary>
|
|||
public class RobidouxSoftResampler : IResampler |
|||
{ |
|||
/// <inheritdoc/>
|
|||
public float Radius => 2; |
|||
|
|||
/// <inheritdoc/>
|
|||
public float GetValue(float x) |
|||
{ |
|||
const float B = 0.6796f; |
|||
const float C = 0.1602f; |
|||
|
|||
return ImageMaths.GetBcValue(x, B, C); |
|||
} |
|||
} |
|||
} |
|||
Loading…
Reference in new issue