Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Initializes a new instance of XMBYTE4 from four float arguments.
This constructor initializes a new instance of XMBYTE4 from four
float arguments.
Syntax
void XMBYTE4(
float _x,
float _y,
float _z,
float _w
) noexcept;
Parameters
_x
Value of the x-coordinate of the vector, the x member of the new
XMBYTE4 instance.
_y
Value of the y-coordinate of the vector, the y member of the new
XMBYTE4 instance.
_z
Value of the z-coordinate of the vector, the z member of the new
XMBYTE4 instance.
_w
Value of the w-coordinate of the vector, the w member of the new
XMBYTE4 instance.
Return value
None
Remarks
The magnitude of each argument to the constructor will be clamped to the range supported by an 8-bit signed integer [-127.0, 127.0].
The following pseudocode demonstrates the operation of this constructor:
XMBYTE4 instance;
instance.x = (int8_t)min( max( _x, -127.0 ), 127.0 );
instance.y = (int8_t)min( max( _y, -127.0 ), 127.0 );
instance.z = (int8_t)min( max( _z, -127.0 ), 127.0 );
instance.w = (int8_t)min( max( _w, -127.0 ), 127.0 );
Requirements
| Requirement | Value |
|---|---|
| Target Platform | Windows |
| Header | directxpackedvector.h |
See also
Reference