ID2D1Geometry::Widen methods
Overload list
| Method | Description |
|---|---|
| Widen(FLOAT,ID2D1StrokeStyle*,D2D1_MATRIX_3X2_F*,ID2D1SimplifiedGeometrySink*) |
Widens the geometry by the specified stroke and writes the result to an ID2D1SimplifiedGeometrySink after it has been transformed by the specified matrix and flattened using the default tolerance. |
| Widen(FLOAT,ID2D1StrokeStyle*,D2D1_MATRIX_3X2_F&,ID2D1SimplifiedGeometrySink*) |
Widens the geometry by the specified stroke and writes the result to an ID2D1SimplifiedGeometrySink after it has been transformed by the specified matrix and flattened using the default tolerance. |
| Widen(FLOAT,ID2D1StrokeStyle*,D2D1_MATRIX_3X2_F*,FLOAT,ID2D1SimplifiedGeometrySink*) |
Widens the geometry by the specified stroke and writes the result to an ID2D1SimplifiedGeometrySink after it has been transformed by the specified matrix and flattened using the specified tolerance. |
| Widen(FLOAT,ID2D1StrokeStyle*,D2D1_MATRIX_3X2_F&,FLOAT,ID2D1SimplifiedGeometrySink*) |
Widens the geometry by the specified stroke and writes the result to an ID2D1SimplifiedGeometrySink after it has been transformed by the specified matrix and flattened using the specified tolerance. |
Examples
The following code example shows how to use Widen to widen the geometry by the specified stroke and then write the result to an ID2D1SimplifiedGeometrySink object.
ID2D1GeometrySink *pGeometrySink = NULL; hr = pPathGeometry->Open(&pGeometrySink); if (SUCCEEDED(hr)) { hr = pGeometry->Widen( strokeWidth, pIStrokeStyle, pWorldTransform, pGeometrySink ); if (SUCCEEDED(hr)) { hr = pGeometrySink->Close(); if (SUCCEEDED(hr)) { ID2D1Mesh *pMesh = NULL; hr = m_pRT->CreateMesh(&pMesh); if (SUCCEEDED(hr)) { ID2D1TessellationSink *pSink = NULL; hr = pMesh->Open(&pSink); if (SUCCEEDED(hr)) { hr = pPathGeometry->Tessellate( NULL, // world transform (already handled in Widen) pSink ); if (SUCCEEDED(hr)) { hr = pSink->Close(); if (SUCCEEDED(hr)) { SafeReplace(&m_pStrokeMesh, pMesh); } } pSink->Release(); } pMesh->Release(); } } } pGeometrySink->Release(); } pPathGeometry->Release();
Requirements
|
Library |
|
|---|---|
|
DLL |
|
See also