Documentation / @ripl/3d / rgbToUnit
Function: rgbToUnit() ​
rgbToUnit(
color):ColorUnitRGB
Defined in: 3d/src/core/color.ts:42
Converts 0–255 RGB channels to the 0–1 range the shading maths and GPU buffers use.
Parameters ​
| Parameter | Type |
|---|---|
color | ColorRGBA |