XMFLOAT3PK::operator uint32_t function (directxpackedvector.h)
Returns an instance of uint32_t
containing the components of the
XMFLOAT3PK
instance in a packed format.
This operator returns an instance of uint32_t
containing the components of the
XMFLOAT3PK instance in a packed format.
Syntax
void operator uint32_t() noexcept;
Return value
Contains the three vector components of an instance of
XMFLOAT3PK
in a packed format.
Remarks
The values of the three components of the current instance of XMFLOAT3PK
are
returned packed in a uint32_t
with the z component (as a reduced precision floating
point number) in the most significant bits, and the x component is stored in the least
significant bits:
(Z10Y11X11): [32] ZZZZZzzz zzYYYYYY yyyyyXXX XXXxxxxx [0]
Or in detail:
- Bits 0-5 of the return value are the 6 bit mantissa of the x component's floating point value.
- Bits 6-10 of the return value are the 5 bit exponent of the x component's floating point value.
- Bits 11-16 of the return value are the 6-bit mantissa of the y component's floating point value.
- Bits 17-21 of the return value are the 5 bit exponent of the y component's floating point value.
- Bits 22-26 of the return value are the 5 bit mantissa of the z component's floating point value.
- Bits 27-31 of the return value are the 5 bit exponent of the z component's floating point value.
Requirements
Requirement | Value |
---|---|
Target Platform | Windows |
Header | directxpackedvector.h |
See also
Reference
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for