watercolor effect?

Hi,

Years ago there was a “Watercolor effect” and/or just “watercolor” in G’MIC, respectively in Black & White and Artistic.

This filter is not listed anymore (2.9.8)
Did it changed its name (if so what’s the new name) or was it removed?

“Watercolor” is still there it is in the “Artistic” group

take that back, the latest gmic for gimp i have is only 2.6.7

installed 2.9.1 correctly, if you look in testing/joan rake/artistic/dreamy watercolor might be a suitable replacement.

Joan is into distortions so hers may not be the kind of watercolour you want.

PS Upon closer inspection, Watercolor is still there but has been commented out perhaps because the code has way too many components to it.

1 Like

@Joan_Rake1 might give more insight. Probably won’t be here though.

Can I un-comment it? if so how? I don’t see any “.gmic” file on my system
May be is it better to un-comment on github, like that users can use it?

From G'MIC - GREYC's Magic for Image Computing: A Full-Featured Open-Source Framework for Image Processing - Adding Custom Commands

At startup, G’MIC automatically includes user’s command file…

Copy-paste the command into the user command file. Remove the # and space at the beginning of each line like so. Then update filters in plugin. It may or may not work properly.

#****************************************
# watercolor
#****************************************

#@gui Watercolor : fx_watercolor, fx_watercolor_preview(1)
#@gui : sep = separator(), note = note("General settings:")
#@gui : Color Intensity = float(1.8,0,4)
#@gui : Light Colors = float(0.1,0,1)
#@gui : Dark Colors = float(1,0,10)
#@gui : sep = separator(), note = note("Line art settings:")
#@gui : Line Art Details = float (80,50,100)
#@gui : Line Art Smoothness = float(0,0,10)
#@gui : Line Art Strength = float(0.5,0,1)
#@gui : Line Art Style = choice("pencil","ink","comic style")
#@gui : Line Art Fade = float(0,0,100)
#@gui : sep = separator(), note = note("Color brushes settings:")
#@gui : Brush Style = choice("modern","classic","abstract","line","smooth")
#@gui : Cyan Brush Size = float(2,0,50)
#@gui : Cyan Stroke Strength = float(0,-5,5)
#@gui : Cyan Edge Distance = float(2,0,10)
#@gui : Cyan Abstraction = float(4,0,10)
#@gui : Magenta Brush Size = float(2,0,50)
#@gui : Magenta Stroke Strength = float(0,-5,5)
#@gui : Magenta Edge Distance = float(3,0,10)
#@gui : Magenta Abstraction = float(3,0,10)
#@gui : Yellow Brush Size = float(2,0,50)
#@gui : Yellow Stroke Strength = float(0,-5,5)
#@gui : Yellow Edge Distance = float(4,0,10)
#@gui : Yellow Abstraction = float(2,0,10)
#@gui : sep = separator(), note = note("Paper and ambience settings:")
#@gui : Paper Color Black = bool(0)
#@gui : Add Paper Texture = bool(0)
#@gui : Invert Colors = bool(0)
#@gui : Ambient Light = float(0,-50,50)
#@gui : sep = separator(), Preview type = choice("Full","Forward horizontal","Forward vertical","Backward horizontal","Backward vertical","Duplicate top","Duplicate left","Duplicate bottom","Duplicate right","Duplicate horizontal","Duplicate vertical","Checkered","Checkered inverse")
#@gui : sep = separator(), note = note("<small>Authors : <i>Tom Keil and Arto Huotari </i>       Latest update: <i>2011/19/02</i>.</small>")
#@gui : note = link("Tutorial download","http://www.slideshare.net/ArtoHuotari/gmig-water-color-filter-tutorial")
#@gui : note = link("Video demonstration here","http://vimeo.com/19713850")
fx_watercolor :
  repeat $! l[$>] split_opacity l[0]
  #secure details:
  if $7==0 +fx_gradient_norm $5,0.5,{99.99-$4},$4,1,0
  elif $7==1 +fx_edges {$5/3.5},{95-$4},0,0
  elif $7==2 +fx_edges {$5/3.5},{95-$4},0,0
  +fx_mix_hsv[0] 1,0,0,1,-1,0,1,0,0,0,2,0
  tk_fx_channel_processing[2] 1,1,0,{$5/10},4,{{$4-50}*2},100,256,0,0,0,2,7,0
  reverse[1,2] fx_compose_multiply[1,2] {0.5+{$6/2}}
  fi fx_frame_round[1] 5,$8,15,0,255,255,255,255,0,0.1,3

  #image preparation:
  fx_smooth_anisotropic[0]
  60,0.16,{{20/50}+0.6},{{20/9}+0.6},2.35,0.8,30,2,0,1,1,0,1
  [0] +negate[0] move[1] 4
  fx_gaussian_blur[2] {{w+h}/100},0,0,1,0,0,0
  fx_compose_dodge[1,2] 1
  fx_mix_lab[0] 1,0,0,$1,0,0,$1,0,0,0,2,0
  reverse[0,1]
  fx_compose_colorburn[0,1] $2

  +luminance[0] reverse[1,2]
  tk_fx_channel_processing[1] 1,1,0,0,4,{$3*5},100,256,0,0,0,2,0,0
  fx_gaussian_blur[1] $3,0,0,1,0,0,0
  tk_fx_channel_processing[1] 1,1,0,0,4,0,99,256,0,1,0,2,0,0
  tk_fx_replace_color[1] 1,0,255,255,255,255,0,0,0,0
  fx_spread[1] {$3*2},{$3*2},0,0
  fx_gaussian_blur[1] {{w+h}/1000},0,0,1,0,0,0
  reverse[0,1] fx_compose_multiply[0,1] 1

  #channel and mask creation:
  split[0] c
  if $9==0 +negate[0] +negate[1] +negate[2]
  elif $9==1 +fill_color[0] 255,255,255 +fill_color[0] 255,255,255
  +fill_color[0] 255,255,255
  elif $9==2 +fill_color[0] 255,255,255 +fill_color[0] 255,255,255
  +fill_color[0] 255,255,255
  elif $9==3 +fx_edges[0] {$10/5},{$13*5},1,0
  +fx_edges[1] {$14/5},{$17*5},1,0 +fx_edges[2] {$18/5},{$21*5},1,0
  elif $9==4 +negate[0] +negate[1] +negate[2] fi

  #channel and mask processing:
  tk_fx_channel_processing[0] 1,{{$11/5}+1},{$11/50},0,0,0,100,256,0,0,0,2,0,0
  if $9!=2
  fx_gaussian_blur[0] $10,0,0,1,0,0,0
  else cubism[0] 300,{$13*5},{$13*36},1,{$10/50} fi
  if $9==0
  tk_fx_channel_processing... 1,{{$11/5}+1},{$11/50},0,0,0,100,256,0,0,0,2,0,0
  cubism... 300,{$13*5},{$13*36},1,{$10/50} fi
  if $9==4
  tk_fx_channel_processing... 1,{{$11/5}+1},{$11/50},0,0,0,100,256,0,0,0,2,0,0
  fx_painting... $13,1.5,2 fi
  fx_frame_fuzzy... {$12*5},{$12*5},{$13*20},{$10/2},0,0,0,255

  tk_fx_channel_processing[1] 1,{{$15/5}+1},{$15/50},0,0,0,100,256,0,0,0,2,0,0
  if $9!=2
  fx_gaussian_blur[1] $14,0,0,1,0,0,0
  else cubism[1] 300,{$17*5},{$17*36},1,{$14/50} fi
  if $9==0
  tk_fx_channel_processing.. 1,{{$15/5}+1},{$15/50},0,0,0,100,256,0,0,0,2,0,0
  cubism.. 300,{$17*5},{$17*36},1,{$14/50} fi
  if $9==4
  tk_fx_channel_processing.. 1,{{$15/5}+1},{$15/50},0,0,0,100,256,0,0,0,2,0,0
  fx_painting.. $17,1.5,2 fi
  fx_frame_fuzzy.. {$16*5},{$16*5},{$17*20},{$14/2},0,0,0,255

  tk_fx_channel_processing[2] 1,{{$19/5}+1},{$19/50},0,0,0,100,256,0,0,0,2,0,0
  if $9!=2
  fx_gaussian_blur[2] $18,0,0,1,0,0,0
  else cubism[2] 300,{$21*5},{$21*36},1,{$18/50} fi
  if $9==0
  tk_fx_channel_processing. 1,{{$19/5}+1},{$19/50},0,0,0,100,256,0,0,0,2,0,0
  cubism. 300,{$21*5},{$21*36},1,{$18/50} fi
  if $9==4
  tk_fx_channel_processing. 1,{{$19/5}+1},{$19/50},0,0,0,100,256,0,0,0,2,0,0
  fx_painting. $21,1.5,2  fi
  fx_frame_fuzzy. {$20*5},{$20*5},{$21*20},{$18/2},0,0,0,255
  to_gray. to_gray.. to_gray... to_rgba[0] to_rgba[1] to_rgba[2]

  #recombine image:
  split[0] c reverse[3,-3] compose_multiply[3,-3] append[0,1,2,3] c
  split[1] c reverse[4,-2] compose_multiply[4,-2] append[1,2,3,4] c
  split[2] c reverse[5,-1] compose_multiply[5,-1] append[2,3,4,5] c
  if $22==0 +fill_color[0] 255,255,255 else +fill_color[0] 0 fi
  reverse[0,-1]  compose_rgba[0,-1]
  if $22==0 +fill_color[1] 255,255,255 else +fill_color[1] 0 fi
  reverse[1,-1] compose_rgba[1,-1]
  if $22==0 +fill_color[2] 255,255,255 else +fill_color[2] 0 fi
  reverse[2,-1] compose_rgba[2,-1]
  to_gray[0] to_gray[1] to_gray[2] append[0,1,2] c
  if $23==1 fx_paper 0,0 fi
  if $24==1 negate[0] fi
  fx_mix_lab 1,$25,0,1,0,0,1,0,0,0,2,0
  reverse[0,1] fx_compose_multiply[0,1] $6
  endl a c endl done

fx_watercolor_preview :
  gui_split_preview "fx_watercolor ${1--2}",$-1

#*****END OF FILTER**********************

1 Like

Thanks a lot @afre
I don’t understand why author removed/comment it, because it works well :+1: (we just need to remove alpha channel from picture)

on top I just added

#@gmic
#@gui _<b>Artistic</b>

Looking up in the gmic-community repository log:

gosgood@bertha ~/git_repositories/gmic-community $ git log -L 1897,2074:/home/gosgood/git_repositories/gmic-community/include/tom_keil.gmic

commit 846a2fe1fe5073d43352cca1e2dc44297fb74edb
Author: David Tschumperlé <David.Tschumperle@gmail.com>
Date:   Tue Sep 8 12:10:17 2020 +0200

    .

diff --git a/include/tom_keil.gmic b/include/tom_keil.gmic
--- a/include/tom_keil.gmic
+++ b/include/tom_keil.gmic
@@ -1868,178 +1868,178 @@
-#@gui Watercolor : fx_watercolor, fx_watercolor_preview(1)
-#@gui : sep = separator(), note = note("General settings:")
… <omitted for brevity>

+# #@gui Watercolor : fx_watercolor, fx_watercolor_preview(1)
+# #@gui : sep = separator(), note = note("General settings:")
… <omitted for brevity>

@David_Tschumperle commented out, likely because it was found not to run on newer gmic releases, and Tom Keil has not been seen for awhile. You may certainly un-comment a version for your own personal .gmic (nèe %APPDATA%\user.gmic for Windows10 ) command file, creating it as needed. You will likely find out the reason it fails, but — if new to gmic — not be able to spelunk how to fix it. The command needs a new maintainer. Bringing it back to life would provide a good, if not exasperating, exercise to learn gmic.

EDIT:

Ah! missed this post. If watercolor fails to manage images with alpha channels, then that would be an annoyance to general users; probably that was the basis for removal of the filter, and fixing watercolor so that one doesn’t have to first remove the alpha channel would be an overall Good Thing. Still could use a maintainer, though such folk are hard to come by and tend not to have much time on their hands…

1 Like