dtof (sm5 - asm)

Component-wise conversion from double-precision floating-point data to single-precision floating-point data.

dtof dest[.mask], [-]src0[.swizzle],
Item Description
dest
[in] The address of the converted data.
src0
[in] The data to be converted.

Remarks

Each component of the source is converted from the double-precision representation to the single-precision representation using round-to-nearest-even rounding.

The valid swizzles for the source parameter are .xyzw, .xyxy, .zwxy, .zwzw.

The valid dest masks are any one or two components. That is: .x, .y, .z, .w, .xy, .xz, .xw, .yz, .yw, .zw The result of the first conversion goes to the first component in the mask, and the result of the second component goes in the second component in the mask, if present.

dest components are float32.

src0 is a double vec2 across (x 32LSB, y 32MSB) and (z 32LSB, w 32MSB) post swizzle.

For float32<->double conversions, implementations may either honor float32 denorms or may flush them.

This instruction applies to the following shader stages:

Vertex Hull Domain Geometry Pixel Compute
X X X X X X

Minimum Shader Model

This instruction is supported in the following shader models:

Shader Model Supported
Shader Model 5 yes
Shader Model 4.1 no
Shader Model 4 no
Shader Model 3 (DirectX HLSL) no
Shader Model 2 (DirectX HLSL) no
Shader Model 1 (DirectX HLSL) no

Shader Model 5 Assembly (DirectX HLSL)