Share via


CD2DGeometry::ComputeArea

Computes the area of the geometry after it has been transformed by the specified matrix and flattened using the specified tolerance.

BOOL ComputeArea(
   const D2D1_MATRIX_3X2_F& worldTransform,
   FLOAT& area,
   FLOAT flatteningTolerance = D2D1_DEFAULT_FLATTENING_TOLERANCE
) const;

Parameters

  • worldTransform
    The transform to apply to this geometry before computing its area.

  • area
    When this method returns, contains a pointer to the area of the transformed, flattened version of this geometry. You must allocate storage for this parameter.

  • flatteningTolerance
    The maximum bounds on the distance between points in the polygonal approximation of the geometry. Smaller values produce more accurate results but cause slower execution.

Return Value

If the method succeeds, it returns TRUE. Otherwise, it returns FALSE.

Requirements

Header: afxrendertarget.h

See Also

Reference

CD2DGeometry Class