// Generated API outline. Implementation bodies omitted. #nullable enable using System.Collections.Generic; using System.ComponentModel; using System.Diagnostics; using System.IO; using System.Linq; using System.Net.Http; using System.Threading.Tasks; using System.Threading; using System; using nfloat = System.Runtime.InteropServices.NFloat; using static Xui.Core.Math2D.Constants; namespace Xui.Core.Canvas.Filter { /// Multiplies paint RGB channels, preserving alpha. One is unchanged; zero is black. public readonly struct Brightness { /// The nonnegative, finite RGB multiplier. public nfloat Amount { get; } /// Creates a brightness adjustment. public Brightness(nfloat amount); } /// The paint color adjustment stored in a canvas state. public enum FilterKind { /// No color adjustment. None, /// Multiply RGB channels by the brightness amount. Brightness, } /// Owned, allocation-free filter state. The default value leaves colors unchanged. public readonly struct FilterState { /// The active adjustment. public FilterKind Kind { get; } /// The brightness multiplier, or one when no adjustment is active. public nfloat Amount { get; } /// Creates state for a brightness adjustment. public FilterState(Brightness brightness); /// Adjusts RGB, clamps each channel to [0,1], and preserves alpha. public Color Apply(Color color); } }