<static> packPixel(r, g, b, a) → {number}
Packs the r, g, b, a components into a single integer, for use with Int32Array.
If device is little endian then ABGR order is used. Otherwise RGBA order is used.
Parameters
Name | Type | Description |
---|---|---|
r | number | The red color component, in the range 0 - 255. |
g | number | The green color component, in the range 0 - 255. |
b | number | The blue color component, in the range 0 - 255. |
a | number | The alpha color component, in the range 0 - 255. |
Returns
number -
The packed color as uint32
- Source code: utils/Color.js (Line 14)
Please login to continue.