This article explains how to use Colour Swatch to set colors.

On the Grasshopper, it is represented by either of the two above.
Setting Colors
Using Colour Swatch, colors can be set.
There are several ways to specify colors, so let’s look at them one by one.
RGB
The first is RGB.
RGB is a method of creating a color by combining Red for red, Green for green, and Blue for blue.
This is the default for Colour Swatch.
By tweaking the color section, you can also intuitively determine the color.
From here, let’s try changing the RGBA slider to determine the color.

If it is not RGB, you can use it by clicking the middle icon in the lower right corner.

By changing the R slider, you can adjust the color on the vertical axis.
The upper side will be a color closer to white.

By changing the G slider, you can adjust the color on the horizontal axis.
The closer to the right, the closer the color is to white.

By changing the B slider, you can adjust the color on the diagonal axis.

By changing the A slider, you can change the transparency.
255 is the maximum value and is not transparent.

By changing the slider of A, you can see that the color is now transparent.
HSV
The second is HSV.
HSV is a method of setting a color using a combination of Hue (hue), Saturation (saturation), and Value (lightness).

To use HSV, click on the right-most icon in the lower right corner.

By changing the Hue slider, you can change the diagonal hue.

By changing the Sat slider, you can change the saturation on the horizontal axis.

By changing the Val slider, you can change the lightness on the vertical axis.

By clicking on the color area, you can also intuitively determine the color.

You can also change the transparency by changing the value of A.
Extracting a favorite color on the screen
You can also extract your favorite colors on the screen.

To use this function, use the left-most icon in the lower right corner.

While holding down the icon, place the cursor over the color you wish to extract.
In this case, I placed the cursor over the pink bin symbol in the upper right corner.
The pink color is now extracted.

Color can also be extracted outside the grasshopper.
Even if the cursor is placed over the area outside the grasshopper, the color could be extracted in this way.
.Using Colour Swatch
Let’s try using Colour Swatch.
This time, we will add color to the sphere created on the glasshopper.

Components used: (1) Sphere (2) Colour Swatch (3) Custom Preview
Connect the sphere created with Sphere to the Custom Preview(G).
By using Custom Preview, the colors and materials set for the object can be displayed.
Then, connect the Colour Swatch to the Custom Preview(M).

As you can see, the color set on the sphere is now reflected.
List of Grasshopper articles using Colour Swatch component↓
Comment