Windows apps
Collapse the table of content
Expand the table of content
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

XMVectorDivide method

Divides one instance of XMVECTOR by a second instance, returning the result in a third instance.

The XMVectorDivide divides each component of an instance of XMVECTOR Data Type by the corresponding component in a second instance of XMVECTOR, returning a new XMVECTOR instance containing the result.

Syntax


XMVECTOR XMVectorDivide(
  [in] XMVECTOR V1,
  [in] XMVECTOR V2
);

Parameters

V1 [in]

XMVECTOR instance whose components are the dividends of the division operation.

V2 [in]

XMVECTOR instance whose components are the divisors of the division operation.

Return value

XMVECTOR instance whose components are the quotient of the division of each component of V1 by each corresponding component of V2.

Remarks

The following code is generally faster than calling XMVectorDivide if the loss of precision is tolerable.



XMVECTOR R = XMVectorReciprocalEst(V2)    
XMVectorMultiply(V1,R)
    

Platform Requirements

Microsoft Visual Studio 2010 or Microsoft Visual Studio 2012 with the Windows SDK for Windows 8. Supported for Win32 desktop apps, Windows Store apps, and Windows Phone 8 apps.

Requirements

Namespace

Use DirectX.

Header

DirectXMath.h

See also

Vector Arithmetic Functions

 

 

Show:
© 2017 Microsoft