Tag Archives: RGB

Use scrollbars to select RGB and HLS colors in C#

The example Convert between RGB and HLS color models in C# explains how to convert between the RGB and HLS color models. This example uses similar code to let the user manipulate scroll bars to select colors using either model. … Continue reading

Posted in algorithms, controls, graphics, image processing | Tagged , , , , , , , , , , , , , , , , , , , , | Leave a comment

Convert between RGB and HLS color models in C#

C# uses uses RGB (red, green, and blue) component values to specify colors where each component value is between 0 and 255. The HLS system uses the values hue, lightness, and saturation where: Hue determines the color with a 0 … Continue reading

Posted in algorithms, graphics, image processing | Tagged , , , , , , , , , , , , , , , , , | 2 Comments

Draw a colorful color wheel in C#

The example Draw a color wheel in C# draws a color wheel. To do that, it makes a series of points along the perimeter of a circle where each point has a different color of the rainbow. It then makes … Continue reading

Posted in drawing, graphics, image processing | Tagged , , , , , , , , , , , | 5 Comments

Draw a color wheel in C#

The program uses a PathGradientBrush to fill a color wheel with color samples. Drawing the wheel is basically automatic but takes some effort to set up. The following DrawColorWheel method draws does all the work. // Draw a color wheel … Continue reading

Posted in drawing, graphics, image processing | Tagged , , , , , , , , , , , | Leave a comment