d3dx9: Avoid variable assignment in D3DXQuaternionNormalize().
This commit is contained in:
parent
db8df8bc7c
commit
5accb12c12
|
@ -1338,23 +1338,20 @@ D3DXQUATERNION* WINAPI D3DXQuaternionMultiply(D3DXQUATERNION *pout, CONST D3DXQU
|
||||||
return pout;
|
return pout;
|
||||||
}
|
}
|
||||||
|
|
||||||
D3DXQUATERNION* WINAPI D3DXQuaternionNormalize(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq)
|
D3DXQUATERNION * WINAPI D3DXQuaternionNormalize(D3DXQUATERNION *out, const D3DXQUATERNION *q)
|
||||||
{
|
{
|
||||||
D3DXQUATERNION out;
|
|
||||||
FLOAT norm;
|
FLOAT norm;
|
||||||
|
|
||||||
TRACE("(%p, %p)\n", pout, pq);
|
TRACE("out %p, q %p\n", out, q);
|
||||||
|
|
||||||
norm = D3DXQuaternionLength(pq);
|
norm = D3DXQuaternionLength(q);
|
||||||
|
|
||||||
out.x = pq->x / norm;
|
out->x = q->x / norm;
|
||||||
out.y = pq->y / norm;
|
out->y = q->y / norm;
|
||||||
out.z = pq->z / norm;
|
out->z = q->z / norm;
|
||||||
out.w = pq->w / norm;
|
out->w = q->w / norm;
|
||||||
|
|
||||||
*pout=out;
|
return out;
|
||||||
|
|
||||||
return pout;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
D3DXQUATERNION * WINAPI D3DXQuaternionRotationAxis(D3DXQUATERNION *out, const D3DXVECTOR3 *v, FLOAT angle)
|
D3DXQUATERNION * WINAPI D3DXQuaternionRotationAxis(D3DXQUATERNION *out, const D3DXVECTOR3 *v, FLOAT angle)
|
||||||
|
|
Loading…
Reference in New Issue