Export (0) Print
Expand All
Expand Minimize

ID2D1RenderTarget::FillGeometry method

Paints the interior of the specified geometry.

Syntax


virtual void FillGeometry(
  [in]            ID2D1Geometry *geometry,
  [in]            ID2D1Brush *brush,
  [in, optional]  ID2D1Brush *opacityBrush = NULL
) = 0;

Parameters

geometry [in]

Type: ID2D1Geometry*

The geometry to paint.

brush [in]

Type: ID2D1Brush*

The brush used to paint the geometry's interior.

opacityBrush [in, optional]

Type: ID2D1Brush*

The opacity mask to apply to the geometry, or NULL for no opacity mask. If an opacity mask (the opacityBrush parameter) is specified, brush must be an ID2D1BitmapBrush that has its x- and y-extend modes set to D2D1_EXTEND_MODE_CLAMP. For more information, see the Remarks section.

Return value

This method does not return a value.

Remarks

If the opacityBrush parameter is not NULL, the alpha value of each pixel of the mapped opacityBrush is used to determine the resulting opacity of each corresponding pixel of the geometry. Only the alpha value of each color in the brush is used for this processing; all other color information is ignored. The alpha value specified by the brush is multiplied by the alpha value of the geometry after the geometry has been painted by brush.

When this method fails, it does not return an error code. To determine whether a drawing operation (such as FillGeometry) failed, check the result returned by the ID2D1RenderTarget::EndDraw or ID2D1RenderTarget::Flush method.

Examples

For an example, see How to Draw and Fill a Complex Shape.

Requirements

Minimum supported client

Windows 7, Windows Vista with SP2 and Platform Update for Windows Vista [desktop apps | Windows Store apps]

Minimum supported server

Windows Server 2008 R2, Windows Server 2008 with SP2 and Platform Update for Windows Server 2008 [desktop apps | Windows Store apps]

Minimum supported phone

Windows Phone 8.1 [Windows Phone Silverlight 8.1 and Windows Runtime apps]

Header

D2d1.h

Library

D2d1.lib

DLL

D2d1.dll

See also

Geometries
Geometries Overview
D2D1_FILL_MODE
ID2D1RenderTarget

 

 

Community Additions

ADD
Show:
© 2014 Microsoft