ID2D1SvgDocument::CreatePaint(D2D1_SVG_PAINT_TYPE,constD2D1_COLOR_F*,PCWSTR,ID2D1SvgPaint**) method (d2d1svg.h)

Creates a paint object which can be used to set the 'fill' or 'stroke' properties.

Syntax

HRESULT CreatePaint(
                 D2D1_SVG_PAINT_TYPE paintType,
  [in, optional] const D2D1_COLOR_F  *color,
  [in, optional] PCWSTR              id,
  [out]          ID2D1SvgPaint       **paint
);

Parameters

paintType

Type: D2D1_SVG_PAINT_TYPE

Specifies the type of paint object to create.

[in, optional] color

Type: const D2D1_COLOR_F*

The color used if the paintType is D2D1_SVG_PAINT_TYPE_COLOR.

[in, optional] id

Type: PCWSTR

The element id which acts as the paint server. This id is used if the paint type is D2D1_SVG_PAINT_TYPE_URI.

[out] paint

Type: ID2D1SvgPaint**

When the method completes, this will contain a pointer to the created paint object.

Return value

Type: HRESULT

This method returns an HRESULT success or error code.

Requirements

Requirement Value
Target Platform Windows
Header d2d1svg.h
DLL Direct2d.dll

See also

ID2D1SvgDocument