asfloat¶
Description¶
Reinterpret bits as a float.
Signature¶
/// Requires Capability Set 1: float asfloat(int x); /// Requires Capability Set 1: float asfloat(uint x); /// Requires Capability Set 1: vector<float, N> asfloat<int N>(vector<int, N> x); /// Requires Capability Set 1: vector<float, N> asfloat<int N>(vector<uint, N> x); /// Requires Capability Set 2: matrix<float, N, M> asfloat<int N, int M>(matrix<int, N, M> x); /// Requires Capability Set 2: matrix<float, N, M> asfloat<int N, int M>(matrix<uint, N, M> x); float asfloat(float x); vector<float, N> asfloat<int N>(vector<float, N> x); matrix<float, N, M> asfloat<int N, int M>(matrix<float, N, M> x);
Generic Parameters¶
N : int¶
M : int¶
Parameters¶
x : int¶
x : uint¶
x : vector<int, N>¶
x : vector<uint, N>¶
x : matrix<int, N, M>¶
x : matrix<uint, N, M>¶
x : float¶
x : vector<float, N>¶
x : matrix<float, N, M>¶
Availability and Requirements¶
Capability Set 1¶
Defined for the following targets:
hlsl¶
Available in all stages.
glsl¶
Available in all stages.
cpp¶
Available in all stages.
cuda¶
Available in all stages.
metal¶
Available in all stages.
wgsl¶
Available in all stages.
spirv¶
Available in all stages.
llvm¶
Available in all stages.
Capability Set 2¶
Defined for the following targets:
hlsl¶
Available in all stages.
glsl¶
Available in all stages.
cpp¶
Available in all stages.
cuda¶
Available in all stages.
metal¶
Available in all stages.
spirv¶
Available in all stages.
llvm¶
Available in all stages.