Colorspaces
✓ Published0🌍 Public
AAjayyy
Last edited Mar 6, 2019
Created on Mar 6, 2019
This visualization uses 500×500 colored pixels to represent the HCL color space across a canvas. It plots hue along the horizontal axis and lightness along the vertical axis, with chroma fixed at 100, showing the full gamut of colors as a smooth, continuous gradient. The code iterates through each pixel coordinate, calling `d3.hcl` from the d3-color library to generate the corresponding color, and draws it on a Canvas element via `d3.range` loops. The example relies on D3 v4 alpha and the d3-scale-chromatic module to provide the color interpolation.
AI-generated descriptionExamples
- Every ColorBrewer Scale
- Matplotlib Colormaps
- ColorBrewer Spline
- ColorBrewer Spline II
- Cubehelix Color Picker
- HSL Color Picker
- HCL Color Picker
- Lab Color Picker
- RGB Color Picker
- A Less-Angry Rainbow
- Cubehelix II
- Lab and HCL Color Spaces
API References
- d3.interpolateViridis et al
- d3 scale chromatic
- d3.color
- d3.rgb
- d3.hsl
- d3.lab
- d3.hcl
- d3.cubehelix
- d3.hsv
forked from <a href='http://bl.ocks.org/alecburch/'>alecburch</a>'s block: <a href='http://bl.ocks.org/alecburch/f822e4381d4124ce199bf72652897274'>Colorspaces</a>
mit Licensed