• Quantizes two f32s to f16 and then packs them in a u32

    This should implement the same behaviour as the builtin pack2x16float from WGSL.

    Caller is responsible to ensuring inputs are f32s


    • x: number

      first f32 to be packed

    • y: number

      second f32 to be packed

    Returns (number | undefined)[]

    an array of possible results for pack2x16float. Elements are either a number or undefined. undefined indicates that any value is valid, since the input went out of bounds.

Generated using TypeDoc