ToDxBrush()
<< Click to Display Table of Contents >> ToDxBrush() |
Converts a WPF Brush to a SharpDX Brush used for SharpDX rendering. Supports SolidColorBrush, LinearGradientBrush, and RadialGradientBrush types.
Note: If you are using a large number of brushes, and are not tied to WPF resources, you should favor creating the SharpDX Brush directly since the ToDxBrush() method can lead to performance issues if called too frequently during a single render pass. |
A new SharpDX.Direct2D1.Brush constructed colors and brush properties of the WPF brush
DxExtensions.ToDxBrush(this System.Windows.Media.Brush brush, RenderTarget renderTarget)
<WPFBrush>.ToDxBrush(RenderTarget renderTarget)
brush |
The System.Windows.Media.Brush to convert |
renderTarget |
The RenderTarget associated with the brush resource |
protected override void OnStateChange() public string TextBrushSerialize |