Winforms C# Gradient Opacity bitmap
问题 I want to make a bitmap that has a linear opacity applied. (i.e. it is more opaque on the left side and get progressively less opaque as it approaches the right.) Is this possible? I know its possible to have a constant opacity level. 回答1: I know its possible to have a constant opacity level So don't make it constant, LinearGradientBrush has no trouble interpolating the alpha value. A simple demonstration of a form that has the BackgroundImage set: protected override void OnPaint