Table of Contents

Class GraphicsOptions

Namespace
SixLabors.ImageSharp
Assembly
SixLabors.ImageSharp.dll

Provides configuration for controlling how graphics operations are rendered, including antialiasing, pixel blending, and alpha composition.

public class GraphicsOptions : IDeepCloneable<GraphicsOptions>
Inheritance
GraphicsOptions
Implements
Inherited Members

Constructors

GraphicsOptions()

Initializes a new instance of the GraphicsOptions class.

public GraphicsOptions()

Properties

AlphaCompositionMode

Gets or sets the alpha composition mode that determines how source and destination alpha channels are combined using Porter-Duff operators. Defaults to SrcOver.

public PixelAlphaCompositionMode AlphaCompositionMode { get; set; }

Property Value

PixelAlphaCompositionMode

Antialias

Gets or sets a value indicating whether antialiasing should be applied. When true, edges are rendered with smooth sub-pixel coverage. When false, coverage is snapped to binary (fully opaque or fully transparent). Defaults to true.

public bool Antialias { get; set; }

Property Value

bool

BlendPercentage

Gets or sets the blending percentage applied to the drawing operation. A value of 1.0 applies the operation at full strength; 0.0 makes it invisible. Valid range is 0 to 1. Defaults to 1.0F.

public float BlendPercentage { get; set; }

Property Value

float

ColorBlendingMode

Gets or sets the color blending mode used to combine source and destination pixel colors. Defaults to Normal.

public PixelColorBlendingMode ColorBlendingMode { get; set; }

Property Value

PixelColorBlendingMode

Methods

DeepClone()

Creates a new GraphicsOptions that is a deep copy of the current instance.

public GraphicsOptions DeepClone()

Returns

GraphicsOptions

The GraphicsOptions.