--- layout: stdlib-reference --- # asint ## Description Reinterpret bits as an int. ## Signature
/// Requires Capability Set 1:
int asint(float x);

/// Requires Capability Set 1:
int asint(uint x);

/// Requires Capability Set 1:
vector<int, N> asint<int N>(vector<float, N> x);

/// Requires Capability Set 1:
vector<int, N> asint<int N>(vector<uint, N> x);

/// Requires Capability Set 2:
matrix<int, N, M> asint<int N, int M>(matrix<float, N, M> x);

/// Requires Capability Set 2:
matrix<int, N, M> asint<int N, int M>(matrix<uint, N, M> x);

int asint(int x);

vector<int, N> asint<int N>(vector<int, N> x);

matrix<int, N, M> asint<int N, int M>(matrix<int, N, M> x);

## Generic Parameters #### N : int #### M : int ## Parameters #### x : float #### x : uint #### x : [vector](../types/vector/index.html)\ #### x : [vector](../types/vector/index.html)\ #### x : [matrix](../types/matrix/index.html)\ #### x : [matrix](../types/matrix/index.html)\ #### x : int #### x : [vector](../types/vector/index.html)\ #### x : [matrix](../types/matrix/index.html)\ ## 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. ### 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. #### spirv Available in all stages.