CreateBrush(Brush,Double,TextureMappingMode) Method
Creates a IBrush2D from WPF Brush valid for the current render pass. Use this to draw rectangles, polygons and shaded areas
Syntax
IBrush2D CreateBrush( Brush brush, double opacity, TextureMappingMode textureMappingMode )
Parameters
- brush
- The WPF Brush to use as a source, e.g. this can be a
, or it can be a . Note that solid colors support transparency and are faster than gradient brushes - opacity
- The opacity of the brush
- textureMappingMode
- Defines a TextureMappingMode, e.g. brushes share a texture per viewport or a new texture per primitive drawn
Return Value
The IBrush2D instance
Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2
See Also