Color palette – PerBang.dk https://www.perbang.dk Per Bang's Personal Toolbox: Lab, Archive and Blog Mon, 01 Dec 2025 11:11:11 +0000 en-US hourly 1 https://wordpress.org/?v=6.9 https://www.perbang.dk/wp-content/themes/pbdk/assets/images/pbdk-favicon.png?1.16.52 Color palette – PerBang.dk https://www.perbang.dk 32 32 Exploring the CLC Color Space in 3D https://www.perbang.dk/exploring-the-clc-color-space-in-3d/ Fri, 28 Nov 2025 01:51:14 +0000 https://www.perbang.dk/?p=258 The CLC (Chroma–Luma Cone) Color Space is a geometric, RGB-derived model designed to make color visualization more intuitive. Unlike traditional 2D representations like HSV or HSL, CLC maps colors into a 3D double-cone structure, allowing you to explore relationships between hue, chroma, and brightness in a visually meaningful way.

How CLC Works

1. Inputs
CLC starts with standard RGB colors, with each channel ranging from 0 to 255. These values are converted to HSV for easier manipulation:

  • H — Hue angle (0–360°)
  • S — Saturation (0–100)
  • V — Value/Brightness (0–100)

2. Geometry
The CLC model arranges colors in a double-cone around a central neutral axis:

  • Horizontal position (x, z) — determined by the color’s chroma radius, which increases with saturation and brightness.
  • Vertical position (y) — represents brightness adjusted by chroma for perceptual neutrality.
    This creates two cones: the upper cone for bright colors, the lower cone for dark colors, with neutral grays forming a smooth central axis.

3. Structure
The resulting 3D structure is:

  • A symmetric, centered double-cone
  • Circular hue wheel around the vertical axis
  • Chromatic colors radiating outward
  • Neutral colors aligned along the center

This design allows CLC to effectively visualize:

  • Color distances and differences
  • Brightness and chroma relationships
  • Large RGB datasets and palettes
  • Palette clustering and analysis

Why CLC is Useful

By translating RGB values into a spatial, 3D representation, CLC makes it easier to understand:

  • Which colors are perceptually similar
  • How brightness and saturation interact
  • The overall distribution of a color palette

It’s an intuitive alternative to standard color spaces and provides a clear, structured view of complex color relationships.

Explore CLC Yourself

You can interact with a live 3D model of CLC colors here: 3D Color Wheel
Double-click any sphere to see detailed information about the color it represents. Switch between CLC, RGB, HSV, and HSL modes to explore different perspectives of your color data.

]]>
How Do I Calculate Color Gradients? https://www.perbang.dk/how-do-i-calculate-color-gradients/ Sat, 28 Sep 2024 09:15:13 +0000 https://www.perbang.dk/?p=159 Ah, the art of color gradients. At first glance, they might seem like a fancy way to spice up a design, but there’s more to gradients than just making things look pretty. Whether you’re designing a website, creating digital art, or simply trying to find that perfect transition from “slightly less offensive yellow” to “kinda tolerable green,” calculating color gradients is both an art and a science. So, how do you calculate them – and why should you care?

The “How” Behind Color Gradients

At its core, calculating a color gradient means finding a smooth transition between two colors. To achieve this, you need to break the journey between your two hex RGB values into manageable steps. Think of it like plotting the stops on a colorful road trip, where each stop is a color between your starting point and destination. The more stops (or “steps”) you make, the smoother your transition will be.

On the handy Gradient Maker, you can do exactly that! You can choose to generate gradients based on:

  • RGB increments: This approach calculates the difference between each color channel (red, green, and blue) and divides them by the number of steps you specify.
  • HSV (Clockwise and Counterclockwise): This method shifts hues around the color wheel, either clockwise or counterclockwise, to create harmonious, hue-based transitions. HSV is great when you want a more natural-feeling gradient, especially for designs that require transitions between different tones and shades.

Simply input two hex RGB values, choose your number of steps (between 3 and 64), and let the Gradient Maker calculate the intermediate colors for you.

The “Why” of Gradients

Why bother calculating gradients at all? Glad you asked! Color gradients are the secret sauce in many digital designs, and their applications are far-reaching:

  • Web Design: Gradients add depth, dimension, and visual interest to websites. By calculating custom gradients, you can create a unique aesthetic that enhances user experience and adds modern flair.
  • Branding: Companies use gradients to make logos, banners, and ads pop. A well-crafted gradient can give your brand a trendy, fresh look without overwhelming your audience.
  • Art & Illustration: Gradients are a powerful tool for creating smooth transitions, adding texture to illustrations, or blending colors in digital artwork. Think of them as the bridge between colors that make your designs more cohesive.
  • Data Visualization: Color gradients are often used to represent ranges or scales in charts, maps, and infographics. For example, heat maps use color transitions to visually indicate differences in data values.

Export Your Results – Or Convert to CSS!

Once your gradient is calculated, the Gradient Maker will display it visually for all types – RGB, HSV Clockwise, and HSV Counterclockwise. But that’s not all. You can easily export the result as a palette, in any of the formats you know and love:

  • GIMP Palette
  • PNG Palette Image
  • Adobe ASE Palette
  • Plain Text (RGB)
  • JSON Format
  • XML (aRGB)

Or, if you’re a web designer looking to apply these gradients to your backgrounds, you can convert your custom gradient directly to CSS backgrounds. Whether you’re using linear or radial gradients, you can copy-paste the CSS and integrate it into your site without breaking a sweat.

So, Why Not?

Gradients are everywhere, from the subtlest backgrounds to bold and colorful designs. They create visual interest, draw attention, and add professionalism to your work. And now, thanks to the Gradient Maker, calculating the perfect gradient is just a few clicks away.

Whether you’re a color connoisseur or just looking to experiment with smooth color transitions, our tool makes it effortless. After all, who doesn’t want a little extra splash of color in their day?

]]>
“Groundbreaking” Color Search and Palette Export https://www.perbang.dk/groundbreaking-color-search-and-palette-export/ Fri, 27 Sep 2024 23:48:33 +0000 https://www.perbang.dk/?p=156 Hold on to your paint buckets, folks! Today marks a historic moment for the site – the color search function (first introduced almost 20 years ago at this site) is now integrated in WordPress and just got even better. Sure, you might argue that a color search tool, which not only helps you find colors by name or hex code but also changes the entire website theme to match the first and best match, is utterly useless. And you’d be right! But in the spirit of embracing life’s little absurdities, it is delightful.

Imagine typing in “coral” or “#ff7f50“, and before you know it, the website transforms into a dazzling display of that hue. Could this feature help you make better life choices? No. Will it improve your productivity? Absolutely not. But it sure does bring your browsing experience into perfect (dis)harmony with the overall chaotic “charm” of the site.

But wait, there’s more! Because who doesn’t want more meaningless, colorful fun? Now, if you search for multiple hex colors, the magic goes even further. The system will identify your colors as a palette, as if by some miracle of modern technology, and will proudly offer you the chance to export that palette in a variety of formats that, in a surprising twist, might actually be useful. Behold your options:

  • GIMP Palette: For the GIMP aficionados, export your palette to work seamlessly with the open-source editor. If you don’t have it already get GIMP here.
  • PNG Palette Image: Sure, it’s just a pretty picture of your palette, but this PNG can also be imported into several apps, including GIMP, as a palette. Double win!
  • Adobe ASE Palette: Fancy using Adobe products? The Adobe Swatch Exchange (.ase) file is a binary file that works with all the posh Adobe tools.
  • Plain Text (RGB): Need those RGB values in a basic text file? Done. It’s simple, it’s effective, and it’s probably the least exciting option -but hey, it’s there.
  • JSON Format: Now we’re talking data! Get all the juicy details – description, RGB, XYZ, and CIELAB values for each color – in a neat JSON file. For when you need to sound smart at parties.
  • XML (aRGB): And here’s the kicker – a surprisingly useful XML resource file with color values in aRGB format. This one actually might have practical value, which, frankly, caught me all off guard.

So, what are you waiting for? Go ahead, search for “hot pink” or “#00FF00 #FF9900 #0099FF“, throw in a few more hex codes, and watch in awe as the site molds itself into your custom palette – because sometimes, the most beautiful things in life are the ones that make the least sense… until suddenly, they do.

]]>