bitcast
On this page

bitcast

Function

Reads the same 32 bits as another type: bitcast<u32>(x) on an f32 and bitcast<f32>(x) on a u32.

The signature and the sentence under each name are the compiler's own text at commit 26de7be8.

Syntax

declare function bitcast<T extends u32 | f32>(e: BitcastArg<T>): T

Parameters

  • e BitcastArg<T>

Return value

T

Description

It reinterprets, it does not convert; u32(x) is the conversion. floatBitsToUint / uintBitsToFloat on GLSL ES 3.00.

Examples

See also

Edit this page Report a problem