Struct ColorStop
A struct that defines a single color stop.
Inherited Members
Namespace: SixLabors.ImageSharp.Drawing.Processing
Assembly: SixLabors.ImageSharp.Drawing.dll
Syntax
public readonly struct ColorStop
Constructors
| Improve this Doc View SourceColorStop(Single, in Color)
Initializes a new instance of the ColorStop struct.
Declaration
public ColorStop(float ratio, in Color color)
Parameters
Type | Name | Description |
---|---|---|
Single | ratio | Where should it be? 0 is at the start, 1 at the end of the Gradient. |
Color | color | What color should be used at that point? |
Properties
| Improve this Doc View SourceColor
Gets the color to be used.
Declaration
public readonly Color Color { get; }
Property Value
Type | Description |
---|---|
Color |
Ratio
Gets the point along the defined gradient axis.
Declaration
public readonly float Ratio { get; }
Property Value
Type | Description |
---|---|
Single |