ID2D1CommandSink::Clear method
Clears the drawing area to the specified color.
Syntax
HRESULT Clear( [in, optional] const D2D1_COLOR_F *clearColor );
Parameters
- clearColor [in, optional]
-
Type: const D2D1_COLOR_F*
The color to which the command sink should be cleared.
Return value
Type: HRESULT
If the method succeeds, it returns S_OK. If it fails, it returns an HRESULT error code.
Remarks
The clear color is restricted by the currently selected clip and layer bounds.
If no color is specified, the color should be interpreted by context. Examples include but are not limited to:
- Transparent black for a premultiplied bitmap target.
- Opaque black for an ignore bitmap target.
- Containing no content (or white) for a printer page.
Requirements
|
Minimum supported client |
Windows 8 and Platform Update for Windows 7 [desktop apps | Windows Store apps] |
|---|---|
|
Minimum supported server |
Windows Server 2012 and Platform Update for Windows Server 2008 R2 [desktop apps | Windows Store apps] |
|
Minimum supported phone |
Windows Phone 8.1 [Windows Phone Silverlight 8.1 and Windows Runtime apps] |
|
Header |
|
|
DLL |
|
See also