Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #@gimp Graduated color accent : gimp_gca, gimp_gca_preview
- #@gimp : Reference color = color(255,255,255)
- #@gimp : Amplitude = float(1,0,5)
- #@gimp : Max value = choice("From input","From reference color","Maximum allowed")
- #@gimp : Channel = choice(0,"Saturation","Lightness")
- #@gimp : sep = separator(), Preview type = choice("Full","Forward horizontal","Forward vertical","Backward horizontal","Backward vertical","Duplicate horizontal","Duplicate vertical")
- #@gimp : sep = separator(), note = note("<small>Author: <i>David Tschumperlé</i>. Latest update: <i>07/15/2015</i>.</small>")
- gimp_gca :
- channel={1+$6}
- -repeat $! -l[$>] -to_color -split_opacity -l[0]
- --fc $1,$2,$3
- --[1] [0] -norm[1] -/[1] {1e-6+iM} -*[1] -1 -+[1] 1 -pow[1] $4
- -rgb2hsl[0] -s[0] c
- -if {$5==0} -*[$channel,-1]
- -elif {$5==1} ($1^$2^$3) -rgb2hsl[-1] -*[$channel] {i[$channel]} -rm[-2,-1]
- -else -rv[$channel,-1] -rm[-1]
- -endif
- -a c -hsl2rgb
- -endl -a c -endl -done
- gimp_gca_preview :
- -gimp_split_preview "-gimp_gca $*",$-1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement