Table of Contents

Struct LinearSegment

Namespace
SixLabors.ImageSharp.Drawing
Assembly
SixLabors.ImageSharp.Drawing.dll

Represents one derived linear segment within a LinearGeometry.

public readonly struct LinearSegment
Inherited Members

Remarks

Instances are produced by SegmentEnumerator and contain the per-segment values required by current backend scene-building code without forcing each backend to recompute them from the endpoints on every iteration.

Properties

End

Gets the segment end point.

public required PointF End { get; init; }

Property Value

PointF

IsHorizontal

Gets a value indicating whether the segment is horizontal.

public required bool IsHorizontal { get; init; }

Property Value

bool

Remarks

A segment is horizontal when Start.Y equals End.Y.

MaxY

Gets the larger of Start.Y and End.Y.

public required float MaxY { get; init; }

Property Value

float

MinY

Gets the smaller of Start.Y and End.Y.

public required float MinY { get; init; }

Property Value

float

Start

Gets the segment start point.

public required PointF Start { get; init; }

Property Value

PointF