f16
constf16:F16
Defined in: packages/typegpu/src/data/numeric.ts:314
A schema that represents a 16-bit float value. (equivalent to f16 in WGSL)
Can also be called to cast a value to an f16.
Examples
Section titled βExamplesβconst value = f16(); // 0const value = f32(1.23); // 1.23const value = f16(true); // 1const value = f16(21877.5); // 21872