intermediate

#12 Color Spaces

HSB/HSV color model for vibrant palettes

RGB mixes red, green, and blue, but HSB (Hue, Saturation, Brightness) is far more intuitive for creating palettes. Hue sweeps through the entire rainbow as a single 0–1 value, saturation controls how vivid the color is, and brightness controls how light or dark. Converting HSB to RGB in the shader lets you generate smooth rainbow gradients, color wheels, and vibrant palettes with minimal effort. Cycling hue over time or space instantly produces eye-catching, harmonious color schemes.

Key Concepts

Try this shader live in the Shader Sandbox editor with real-time preview.
Open in Sandbox

Source Code


    
← Previous Rotation & Transforms Next → Polar Coordinates

All Tutorials