ID2D1BitmapBrush interface (d2d1.h)

Paints an area with a bitmap.

Inheritance

The ID2D1BitmapBrush interface inherits from ID2D1Brush. ID2D1BitmapBrush also has these types of members:

Methods

The ID2D1BitmapBrush interface has these methods.

 
ID2D1BitmapBrush::GetBitmap

Gets the bitmap source that this brush uses to paint.
ID2D1BitmapBrush::GetExtendModeX

Gets the method by which the brush horizontally tiles those areas that extend past its bitmap.
ID2D1BitmapBrush::GetExtendModeY

Gets the method by which the brush vertically tiles those areas that extend past its bitmap.
ID2D1BitmapBrush::GetInterpolationMode

Gets the interpolation method used when the brush bitmap is scaled or rotated.
ID2D1BitmapBrush::SetBitmap

Specifies the bitmap source that this brush uses to paint.
ID2D1BitmapBrush::SetExtendModeX

Specifies how the brush horizontally tiles those areas that extend past its bitmap.
ID2D1BitmapBrush::SetExtendModeY

Specifies how the brush vertically tiles those areas that extend past its bitmap.
ID2D1BitmapBrush::SetInterpolationMode

Specifies the interpolation mode used when the brush bitmap is scaled or rotated.

Remarks

A bitmap brush is used to fill a geometry with a bitmap. Like all brushes, it defines an infinite plane of content. Because bitmaps are finite, the brush relies on an "extend mode" to determine how the plane is filled horizontally and vertically.

Creating ID2D1BitmapBrush Objects

To create a bitmap brush, use the ID2D1RenderTarget::CreateBitmapBrush method.

An ID2D1BitmapBrush is a device-dependent resource: your application should create bitmap brushes after it initializes the render target with which the bitmap brush will be used, and recreate the bitmap brush whenever the render target needs recreated. (For more information about resources, see Resources Overview.)

Examples

For an example of how to create a bitmap brush, see the How to Create a Bitmap Brush topic.

Requirements

Requirement Value
Minimum supported client Windows 7, Windows Vista with SP2 and Platform Update for Windows Vista [desktop apps | UWP apps]
Minimum supported server Windows Server 2008 R2, Windows Server 2008 with SP2 and Platform Update for Windows Server 2008 [desktop apps | UWP apps]
Target Platform Windows
Header d2d1.h

See also

Brushes Overview

How to Create a Bitmap Brush

ID2D1Brush

Opacity Masks Overview