Tuesday, September 19, 2023

Blend

 Was wondering, this morning, if the order in which one stacked

colors of differing opacity made any difference. Turns out it does not,

Below, using 17% opacity not to get rounding.


                                                           


Then asked Chatgpt about blending modes:

                                                               In **computer graphics**, a **blending mode** is a mathematical equation that defines how pixels from two or more layers are combined to create a composite image³. It determines how the color information in the layers is blended together. The default blend mode in most applications is to obscure the lower layer by covering it with whatever is present in the top layer¹. However, there are many other ways to blend two layers, and most graphics editing programs allow users to modify the basic blend modes¹.


Here are a few examples of common blend modes:


- **Normal**: This is the standard blend mode that uses only the top layer without mixing its colors with the layer beneath it¹.

- **Multiply**: This blend mode darkens the image by multiplying the RGB channel values of each pixel in the top layer with the corresponding pixel values from the bottom layer¹.

- **Screen**: This blend mode lightens the image by multiplying the inverse of the RGB channel values of each pixel in the top layer with the corresponding pixel values from the bottom layer¹.

- **Overlay**: This blend mode combines Multiply and Screen modes to create a contrast-rich image¹.

- **Soft Light**: This blend mode applies a softer version of Overlay mode, resulting in a subtle lighting effect¹.


These are just a few examples, and there are many more blend modes available in different computer graphics software. Each blend mode has its own unique effect on how pixels are blended together.


Let me know if you have any more questions! 😊


Source: Conversation with Bing, 9/19/2023

(1) Blending Modes: A Complete Guide for Graphic and Web Design. https://www.elegantthemes.com/blog/design/blending-modes.

(2) Blend modes - Wikipedia. https://en.wikipedia.org/wiki/Blend_modes.

(3) Blending Modes Explained - Videomaker. https://www.videomaker.com/article/c03/18076-blending-modes-explained/.

(4) Alpha compositing - Wikipedia. https://en.wikipedia.org/wiki/Alpha_compositing.

(5) What blend mode is this? - Computer Graphics Stack Exchange. https://computergraphics.stackexchange.com/questions/6407/what-blend-mode-is-this


Did a multipleexample, the hard way. Set the two reference colors at 100% opacity,

found what the various channels on each were on a scale of 0 to 1, and multiplied. ended

up with the color in the triangle.


Looked up blend modes in Photoshop to make sure that was it; it was.

Smarten up to the act that blend modes were offered on the Expression Blend interface

I do have...


                                                                               


                                                                 



*     *     *
Both buttons are now ttk styled.

There is a relief option. One can dramatize things by specifying borderwidth.

The relief options are: flat, raised, sunken, groove, ridge...

                                                         


A button will change color when the mouse hovers, thanks to the map() function:

                                                          
                                                                  



                                                                                

No comments: