This topic has not yet been rated - Rate this topic

Matrix3x2F::Scale(D2D1_SIZE_F, D2D1_POINT_2F) method

Creates a scale transformation that has the specified scale factors and center point.

Syntax


static Matrix3x2F Scale(
  D2D1_SIZE_F size,
  D2D1_POINT_2F centerPoint = D2D1::Point2F()
);

Parameters

size

Type: D2D1_SIZE_F

The x-axis and y-axis scale factors of the scale transformation.

centerPoint

Type: D2D1_POINT_2F

The point about which the scale is performed.

Return value

Type: Matrix3x2F

The new scale transformation.

Remarks

This method creates a scale transformation for the specified centerPoint and scale factors. The scale factors are stored as an ordered pair in the D2D1_SIZE_F structure. If you prefer to list each scale factor as a parameter, call the other Scale method.

The following illustration shows the size of the square increased to 130% in each dimension. The center point for the scaling is the upper-left corner of the square.

Illustration of a square scaled by 130% in the x-direction and y-direction

For an example, see How to Scale an Object.

Requirements

Minimum supported client

Windows 7, Windows Vista with SP2 and Platform Update for Windows Vista [desktop apps only]

Minimum supported server

Windows Server 2008 R2, Windows Server 2008 with SP2 and Platform Update for Windows Server 2008 [desktop apps only]

Namespace

D2D1

Header

D2d1helper.h

Library

D2d1.lib

DLL

D2d1.dll

See also

Matrix3x2F

 

 

Send comments about this topic to Microsoft

Build date: 11/29/2012

Did you find this helpful?
(1500 characters remaining)

Community Additions

ADD
© 2013 Microsoft. All rights reserved.