It is currently Thu Apr 25, 2024 7:38 pm


All times are UTC - 5 hours [ DST ]



Post new topic Reply to topic  [ 11 posts ] 
Author Message
 Post subject: .
PostPosted: Sun Jun 24, 2012 9:49 pm  (#1) 
Offline
GimpChat Member

Joined: Apr 19, 2012
Posts: 80
Location: Australia
.


Last edited by b10h4z4rd on Sun Jul 08, 2012 5:02 pm, edited 2 times in total.

Share on Facebook Share on Twitter Share on Orkut Share on Digg Share on MySpace Share on Delicious Share on Technorati
Top
 Post subject: Re: Layer Modes (Blending Modes)
PostPosted: Sun Jun 24, 2012 10:41 pm  (#2) 
Offline
Global Moderator
User avatar

Joined: Nov 16, 2011
Posts: 5128
Location: Metro Vancouver, BC
Nice links, some really good info there. I could read those over and over and not remember even half of it. If I don't use it, I lose it.

_________________
Image
Gimp 2.8.18, Linux, median user
Gimp Chat Tutorials Index
Spirit Bear (Kermode)


Top
 Post subject: Re: Layer Modes (Blending Modes)
PostPosted: Mon Jun 25, 2012 4:23 pm  (#3) 
Offline
Script Coder

Joined: Apr 10, 2011
Posts: 532
    GIMP layer modes


    First of all, it's important to know how pixels work in a graphics software. Each pixel has 3 colour values, red, green and blue, each has a value between 0 and 255. A pixel with all values at 0 is black, and one with all values at 255 is white.

    Layer modes effect how the pixels in a layer are mixed with the pixels of lower layers. Think of each layer mode as an equation that is performed on the pixel values. The layer mode equation is calculated first, and the resulting colours are mixed according the opacity of the layer.

    Here are the most important layer modes in GIMP:

  • Normal

    Boring... this is the default mode, which uses no equation - the previous layers won't affect the colours of the layer. At 100% opacity, this mode is totally opaque (ie. non-transparent).

  • Multiply

    Multiply multiplies the lower value with the upper value and divides the result with 255. In practice, it means that all white pixels (value 255) in your layer are invisible, and everything darker than white makes the result darker.

    Note that this is per colour channel: if your layer has a red pixel (255,0,0) and the layers below have a grey pixel, let's say (100,100,100), then the resulting pixel will be (100,0,0) - the red channel is unaffected, while green and blue are multiplied by 0.

  • Screen

    This is basically the polar opposite of multiply. All the black pixels in your layer are invisible, and anything brighter than black makes the result brighter. Like multiply, this also works per colour channel.

  • Hard light

    This is basically a combination of multiply and screen. If your layer has a colour value that is below the average (128), then hard light works like multiply, ie. colour values 0-127 work like values 0-255 in multiply mode.

    If your layer's colour value is 128 or higher, the mode works like screen, ie. colour values 128-255 work like values 0-255 in screen mode.

    In effect: 128 is invisible, anything lower makes the result darker, and anything higher makes the result brighter.

  • Soft light/Overlay (Due to a bug, soft light & overlay are in practice identical in GIMP)

    Soft light uses a fairly complex equation, so I'm not going to go into that here. Suffice it to say that it's like a "weaker" version of hard light: it affects the colours less strongly. If the lower layers have white or black, soft light won't affect them at all. Grey values are affected most strongly.

    Like hard light, on soft light, 128 is invisible, while higher values make the result brighter and lower values make the result darker.

  • Grain merge

    This is a very useful mode, although it's fairly simple. It takes the value from your layer, substracts 128 from it, so that the value is between -128 and 127, and then adds that to the lower layers' value.

    So again, 128 is invisible, while lower values make the result darker, etc.

    Grain extract is basically the inverse of grain merge, ie. it's the same as inverting all the values on your layer and then using grain merge.

  • The differences between hard light, soft light and grain merge:

    These modes all function in similar ways, but there are differences.

    Hard light is the most uncompromising and absolute: anything white or black on a hard light layer results in white or black.

    Grain merge is a simple addition/substraction, it doesn't care what is under it, it affects everything the same way. However, the differences are more pronounced on darker areas, since the relative differential is higher.
    Soft light is like a tender, gentle, hard light - it's like a hard light with self-confidence issues: if anything under it is too strong (ie. black or white) it doesn't dare touch them. The closer the underlying values are to average (128), the stronger soft light affects it.


    There are some other layer modes, but I don't use them all that much. Experimentation is the best way to figure out how they function.


Top
 Post subject: Re: Layer Modes (Blending Modes)
PostPosted: Mon Jun 25, 2012 6:46 pm  (#4) 
Offline
GimpChat Member

Joined: Apr 12, 2010
Posts: 5870
Well 3 that you left out are very useful and the most simple to explain, the name is self explanatory :

Lighten only:

each pixel is confronted and only the whiter are used
example of use : you want add a moon to a image of the blue sky; if the background of the moon is darker then the blue of the sky
you don't need to cut the moon...just use Lighten Only will transfer only the moon

Darken Only

just the opposite

so as example you may add black bird flying on a clear sky, to another but darker sky without have to cut

Difference

is used to spot differences
if are no difference (2 identical layers perfectly aligned ) result is just solid black
if are differences are marked by colors

may be useful to perfectly align very similar images ,check if a duplicate is perfect and so on
it is also used for wild psychedelic effect (usually hard to dose..sometimes the effect is cool but usually is very hard to calculate in advance .. more a hit or miss )

_________________
My 3D Gallery on Deviantart http://photocomix2.deviantart.com/
Main gallery http://www.flickriver.com/photos/photocomix-mandala/
Mandala and simmetry http://www.flickriver.com/photos/photocomix_mandala/

Image

Mrs Wilbress


Top
 Post subject: Re: Layer Modes (Blending Modes)
PostPosted: Mon Jun 25, 2012 6:58 pm  (#5) 
Offline
GimpChat Member
User avatar

Joined: Jun 24, 2010
Posts: 504
Location: Western Vic Australia
Each layer mode is explained in detail (with diagrams and Mathematical formulae) in the Gimp Help Section 2 Layermodes Chapter 8
If you have Help installed , it can probably be found in your installed file C:/ProgramFiles/GIMP-2.0/share/gimp/2.0/help/en/gimp-concepts-layer-modes.html. It is also explained in "Grokking the Gimp", an online publication .

_________________
Image


Top
 Post subject: Re: Layer Modes (Blending Modes)
PostPosted: Mon Jun 25, 2012 7:02 pm  (#6) 
Offline
GimpChat Member
User avatar

Joined: Mar 23, 2012
Posts: 7309
Location: Göteborg at last!
Grokking the Gimp is an excellent manual.


Top
 Post subject: Re: Layer Modes (Blending Modes)
PostPosted: Mon Jun 25, 2012 7:29 pm  (#7) 
Offline
GimpChat Member

Joined: Apr 12, 2010
Posts: 5870
Sure but some found the explication too complex and technical so a summary in simple words may be handy

so i finish with Color and Value ..that too are quite useful and self explanatory

Color

Basically transfer the colors (saturation and hue) from the top layer on the greyscale (value or luminosity ) of the BG layer

It should and it does ...but human minds and eyes perceive colors in a more sophisticated way not just as a combination of hue and saturation so sometimes result is not exactly what expected

Value

it is just the opposite, transfer the greyscale (1 of the possible way to interpret the greyscale ) of the top layer on the layer below , maintaining the original colors of the bg layer

Value is very useful, as example unsharp and contrast mask tend to modify also the colors not only the contrast, but if you first dup the layer and apply the unsharpmask to the dup, setting the dup to value, the effect on the contrast would be the same but the colors shift will be minimized

_________________
My 3D Gallery on Deviantart http://photocomix2.deviantart.com/
Main gallery http://www.flickriver.com/photos/photocomix-mandala/
Mandala and simmetry http://www.flickriver.com/photos/photocomix_mandala/

Image

Mrs Wilbress


Top
 Post subject: Re: Layer Modes (Blending Modes)
PostPosted: Tue Jun 26, 2012 1:25 am  (#8) 
Offline
GimpChat Member
User avatar

Joined: May 26, 2012
Posts: 342
Location: France
dd wrote:
  • Soft light/Overlay (Due to a bug, soft light & overlay are in practice identical in GIMP)


...I always wondered why, I ended up believing it was an easter egg :D


Top
 Post subject: Re: Layer Modes (Blending Modes)
PostPosted: Tue Jun 26, 2012 8:48 am  (#9) 
Offline
GimpChat Member

Joined: Apr 12, 2010
Posts: 5870
why is simple, the formulas are different but result is anyway similar...
so similar that the needed rounding (to speed up calculation and similar) made them totally identical.

Obviously was a error but could not be fixed without breaking backward compatibility so fix was postponed waiting for Gegl..
(should be almost time now)

But the real overlay (as several modes absent in Gimp) may be used from gmic (or even mathmap )

_________________
My 3D Gallery on Deviantart http://photocomix2.deviantart.com/
Main gallery http://www.flickriver.com/photos/photocomix-mandala/
Mandala and simmetry http://www.flickriver.com/photos/photocomix_mandala/

Image

Mrs Wilbress


Top
 Post subject: Re: Layer Modes (Blending Modes)
PostPosted: Tue Jun 26, 2012 10:32 am  (#10) 
Offline
GimpChat Member
User avatar

Joined: May 26, 2012
Posts: 342
Location: France
Ok, I didn't know you can have it with G'mic (I dropped g'mic some time ago mainly because all I wanted was GreyCstoration), I might want to recheck g'mic after all, thanks for the tip (:


Top
 Post subject: Re: Layer Modes (Blending Modes)
PostPosted: Wed Jun 27, 2012 5:41 pm  (#11) 
Offline
Script Coder

Joined: Apr 10, 2011
Posts: 532
PhotoComix wrote:
Lighten only:

each pixel is confronted and only the whiter are used
example of use : you want add a moon to a image of the blue sky; if the background of the moon is darker then the blue of the sky
you don't need to cut the moon...just use Lighten Only will transfer only the moon


Actually, Lighten & Darken work on a channel-by-channel basis - if you mix yellow on lighten on top of blue, you will get white, as it picks the lightest channel from each colour (1, 1, 0 + 0, 0, 1 = 1, 1, 1).

Almost all the layer modes work this way, the only exceptions are the HSV/Lab-based ones (Value, Color, etc.)

anarkhya wrote:
..I always wondered why, I ended up believing it was an easter egg :D


Actually it seems to have been fixed in 2.8. I wrote that thing way back before 2.8 was released and just pasted it here directly...


Top
Post new topic Reply to topic  [ 11 posts ] 

All times are UTC - 5 hours [ DST ]



* Login  



Powered by phpBB3 © phpBB Group