It is currently Fri Apr 19, 2024 3:35 am


All times are UTC - 5 hours [ DST ]



Post new topic Reply to topic  [ 29 posts ]  Go to page 1, 2  Next
Author Message
 Post subject: Is there a plugin - hue/saturation adjustment
PostPosted: Mon Aug 22, 2011 2:25 pm  (#1) 
Offline
Script Coder

Joined: Apr 10, 2011
Posts: 532
Is there a plugin for GIMP (well duh..) that can adjust the hue/saturation of an image while preserving the luminosity?

The built in Hue/Saturation/Lightness adjustment adjusts a layer based on HSV values. The HSV system is flawed in that two colours with the same value and saturation can have very different perceived brightness. For example, if you have a layer of bright blue (0000ff) and you adjust the hue a half circle, you get bright yellow (ffff00) which is way more bright than the blue. Both colours have the same saturation and value in the HSV system, but the other is many times brighter actually...

So... is there an existing plugin that would do the same as the built-in hue/saturation/lightness adjust, but would work in H/C/Y (hue-chroma-luminosity) colour... or, allow adjusting the hue/saturation while preserving luminosity?

For reference: luminosity refers to the perceived brightness of a colour, it's different from both lightness and value. The desaturate -function has an option of using luminosity when converting to grayscale.

I just want to know if there is an existing plugin/script for this before I start writing one, because writing one would not be a small task...


Last edited by dd on Mon Aug 22, 2011 6:45 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: Is there a plugin - hue/saturation adjustment
PostPosted: Mon Aug 22, 2011 6:12 pm  (#2) 
Offline
GimpChat Member

Joined: Mar 14, 2011
Posts: 998
I don't know if this helps. Have you looked at the saturation equalizer? It's in the registry and included in the "useful plugins" that I provide.

Partha


Top
 Post subject: Re: Is there a plugin - hue/saturation adjustment
PostPosted: Mon Aug 22, 2011 6:45 pm  (#3) 
Offline
Script Coder

Joined: Apr 10, 2011
Posts: 532
partha wrote:
I don't know if this helps. Have you looked at the saturation equalizer? It's in the registry and included in the "useful plugins" that I provide.

Partha


While that seems interesting and useful in itself, it isn't quite what I'm looking for... thanks though.


Top
 Post subject: Re: Is there a plugin - hue/saturation adjustment
PostPosted: Tue Aug 23, 2011 10:04 am  (#4) 
Offline
Script Coder

Joined: Apr 10, 2011
Posts: 532
Well, I figured out a pretty easy way to do this.

First, take the layer you want to adjust. Take a copy of it, desaturate the copy with luminosity setting and name the copy "lum".

Then make the hue/saturation adjustments you want on the original.

Now, make another copy of the original, desaturate it again with luminosity, set it on grain extract and merge with the original. Now the original has all luminosity removed from it, and the hue has been adjusted... but we still have the "lum" layer that has the original luminosity information. Simply set it on grain merge, merge it with the original, and voilá.

Now I'll just have to write a script for this.


Top
 Post subject: Re: Is there a plugin - hue/saturation adjustment
PostPosted: Tue Aug 23, 2011 11:57 am  (#5) 
Offline
GimpChat Member

Joined: Apr 12, 2010
Posts: 5870
.
Quote:
For example, if you have a layer of bright blue (0000ff) and you adjust the hue a half circle, you get bright yellow (ffff00) which is way more bright than the blue. Both colours have the same saturation and value in the HSV system, but the other is many times brighter actually...


I believe just impossible have a color seen by human eyes as a "dark yellow", meaning dark as blue...because yellow will be never felt as dark , or if percived as dark would be no more felt as yellow.(but will be see as brown )

you may give more or less brightness to blue,or red, but for yellow you may only add some brightness (resulting in a whiter yellow) but as soon you start to lower its brightness the human eyes refuse to see the resulting color as something close to yellow

Anyway maybe you may found something useful in the "color" submenu of GMIC, as the varius color mixer

_________________
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: Is there a plugin - hue/saturation adjustment
PostPosted: Tue Aug 23, 2011 12:05 pm  (#6) 
Offline
Script Coder

Joined: Apr 10, 2011
Posts: 532
Quote:
I believe just impossible have a color seen by human eyes as a "dark yellow", meaning dark as blue...because yellow will be never felt as dark , or if percived as dark would be no more felt as yellow.(but will be see as brown )


Well, it depends on the surrounding colours as well. Colour perception is not absolute, it's about the frame of reference.

For example, if you have a photograph of a room with yellow curtains on the window, and a photograph of the same room in the dark / low lighting... then the actual colour of the curtains in the photo can be "brown" but with the frame of reference you can still perceive it as yellow.

Anyway, I'll be writing a script for this when I have time.

Image


Top
 Post subject: Re: Is there a plugin - hue/saturation adjustment
PostPosted: Tue Aug 23, 2011 12:28 pm  (#7) 
Offline
GimpChat Member
User avatar

Joined: Jan 13, 2011
Posts: 2240
Location: Poland
Men usually do not distinguish and so the color subtleties ....
Very waiting for scrript - and agree with an opinion of women...color belongs to the Women's...

_________________
Image

Slava
Ukraini!


Top
 Post subject: Re: Is there a plugin - hue/saturation adjustment
PostPosted: Tue Aug 23, 2011 1:38 pm  (#8) 
Offline
Script Coder
User avatar

Joined: Jul 14, 2010
Posts: 697
MareroQ wrote:
Men usually do not distinguish and so the color subtleties ....
Very waiting for scrript - and agree with an opinion of women...color belongs to the Women's...


FromDogHouse Diaries:
Image

-Rob A>

_________________
Image
Fantasy Cartography and Mapping by RobA


Top
 Post subject: Re: Is there a plugin - hue/saturation adjustment
PostPosted: Tue Aug 23, 2011 1:53 pm  (#9) 
Offline
Retired Staff
User avatar

Joined: May 22, 2008
Posts: 6947
Location: Somewhere in GIMP
:clap That is so right, RobA. :lol

_________________
Image
World War IV will be fought with sticks and stones. - Albert Einstein


Top
 Post subject: Re: Is there a plugin - hue/saturation adjustment
PostPosted: Tue Aug 23, 2011 2:10 pm  (#10) 
Offline
GimpChat Member
User avatar

Joined: Sep 24, 2010
Posts: 12516
Excellent Rob. lol

I know it's wrong, but I always classify cyan as blue too; sometimes though, I call it sky blue. ;)

:)

_________________
Lyle

Psalm 109:8

Image


Top
 Post subject: Re: Is there a plugin - hue/saturation adjustment
PostPosted: Tue Aug 23, 2011 2:23 pm  (#11) 
Offline
GimpChat Member
User avatar

Joined: Sep 24, 2010
Posts: 12516
OK dd; I'll share a secret with you (and all). I, more then often, create a color amplication layer using Luma Invert (http://registry.gimp.org/node/8352). I dup, run Luma Invert, then set opacity to 50% and merge down. I then set this layer to Grain Merge and use Hue/Saturation adjustment to control how the colors/saturation/lighting gets applied. Below's something that I just did recently (of course the result is pretty extreme/intense). :)

http://forums.dpreview.com/forums/read. ... nreal&qf=m

_________________
Lyle

Psalm 109:8

Image


Top
 Post subject: Re: Is there a plugin - hue/saturation adjustment
PostPosted: Tue Aug 23, 2011 2:42 pm  (#12) 
Offline
Script Coder

Joined: Apr 10, 2011
Posts: 532
Alright, here's the new script - in fact, it's three scripts in one.

http://www.fileden.com/files/2010/2/7/2 ... minance.py

It installs 3 menu options to a submenu "Luminance" under Filters. I'll go through them briefly...

"Remove" simply removes all luminance information from a layer, leaving only the chroma. In other words, it sets the luminance of a layer 50% on the whole layer.

"Extract" extracts the luminance into a new layer, or in other words: it separates a layer to luminance and chroma. The luminance layer is automatically set on grain merge, so the result should be identical to the previous layer.

And finally...

"Hue-Saturation" - this uses the earlier two scripts internally to the effect of allowing you to adjust the hue and saturation of a layer while preserving the luminance of it intact.

I might be writing a more advanced version of the hue-saturation script, if I have time some day... for now, if you want a better interface, simply use the Extract to extract the luminance, adjust the chroma layer with the native hsl tool, then remove luminance from it, and merge the luminance down. (as that is basically what the hue/sat script does...)


Top
 Post subject: Re: Is there a plugin - hue/saturation adjustment
PostPosted: Wed Aug 24, 2011 6:01 am  (#13) 
Offline
Script Coder

Joined: Apr 10, 2011
Posts: 532
There is now a registry page for the luminance scripts.

http://registry.gimp.org/node/25522

btw thanks Lyle, I'll try that technique sometime.


Top
 Post subject: Re: Is there a plugin - hue/saturation adjustment
PostPosted: Wed Aug 24, 2011 6:22 am  (#14) 
Offline
Global Moderator
User avatar

Joined: Apr 07, 2010
Posts: 14182
Very nice script dd. thanx for sharing.

_________________
Image


Top
 Post subject: Re: Is there a plugin - hue/saturation adjustment
PostPosted: Wed Aug 24, 2011 9:40 am  (#15) 
Offline
Retired Staff
User avatar

Joined: May 22, 2008
Posts: 6947
Location: Somewhere in GIMP
lylejk wrote:
I know it's wrong, but I always classify cyan as blue too; sometimes though, I call it sky blue.
I always think of cyan as blue. According to wiki, it straddles the line between blue and green.
http://en.wikipedia.org/wiki/Cyan

After using gimp for a few years, I even refer to cyan as cyan sometimes and I get strange looks from people. :lol

_________________
Image
World War IV will be fought with sticks and stones. - Albert Einstein


Top
 Post subject: Re: Is there a plugin - hue/saturation adjustment
PostPosted: Wed Aug 24, 2011 11:30 am  (#16) 
Offline
GimpChat Member
User avatar

Joined: Jan 13, 2011
Posts: 2240
Location: Poland
Thanks to DD for the plugin.
Something about the color naming ...
http://www.gimpchat.com/viewtopic.php?f=9&t=2417#p31175

_________________
Image

Slava
Ukraini!


Top
 Post subject: Re: Is there a plugin - hue/saturation adjustment
PostPosted: Wed Aug 24, 2011 11:39 am  (#17) 
Offline
Retired Staff
User avatar

Joined: May 22, 2008
Posts: 6947
Location: Somewhere in GIMP
dd wrote:
There is now a registry page for the luminance scripts.

http://registry.gimp.org/node/25522

btw thanks Lyle, I'll try that technique sometime.
I've been playing with this plug-in. I used this satin image to test it out.

First I extracted the luminance. Then on the color layer, I used Color > Hue & Saturation as it lets me see what is happening rather H & S that came with the Luminance plug-in.

I love it that the script preserves the luminance. I used the new Bevel script. My image shows the difference of using the luminance extraction and not using it.
Image

I love the translucent quality it lends to this one.

Image


Top
 Post subject: Re: Is there a plugin - hue/saturation adjustment
PostPosted: Wed Aug 24, 2011 12:04 pm  (#18) 
Offline
GimpChat Member
User avatar

Joined: Sep 24, 2010
Posts: 12516
Left you a message at the Registry, but I have to thank you here too dd. Excellent python plugin. :)

_________________
Lyle

Psalm 109:8

Image


Top
 Post subject: Re: Is there a plugin - hue/saturation adjustment
PostPosted: Wed Aug 24, 2011 12:30 pm  (#19) 
Offline
Retired Staff
User avatar

Joined: May 22, 2008
Posts: 6947
Location: Somewhere in GIMP
I love using the two plug-ins together: Bevel and Luminance.

Image

_________________
Image
World War IV will be fought with sticks and stones. - Albert Einstein


Top
 Post subject: Re: Is there a plugin - hue/saturation adjustment
PostPosted: Wed Aug 24, 2011 1:35 pm  (#20) 
Offline
Global Moderator
User avatar

Joined: Apr 07, 2010
Posts: 14182
That is very nice "O"

_________________
Image


Top
Post new topic Reply to topic  [ 29 posts ]  Go to page 1, 2  Next

All times are UTC - 5 hours [ DST ]


   Similar Topics   Replies 
No new posts Attachment(s) GEGL Vibrance - fancy saturation plugin (probably canceled)

8

No new posts Gimp's adjustment layers

1

No new posts Attachment(s) Matching my Phone Camera's 'Brightness' Adjustment

1

No new posts Attachment(s) New GEGL Filter that combines existing adjustment filters in one place

4

No new posts Getting Black from Hue/Saturation

1



* Login  



Powered by phpBB3 © phpBB Group