Function glm::builtin::packUnorm2x16 [] [src]

pub fn packUnorm2x16(v: Vec2) -> u32

First, converts each component of the normalized floating-point value v into 16-bit integer values. Then, the results are packed into the returned 32-bit unsigned integer.

The conversion for component c of v to fixed point is done as follows: round(clamp(c, 0, 1) * 65535.0)

The first component of the vector will be written to the least significant bits of the output; the last component will be written to the most significant bits.

Example