GIMP Chat
http://gimpchat.com/

cli345's cartoon filter as a native GEGL Filter.
http://gimpchat.com/viewtopic.php?f=9&t=20110
Page 1 of 1

Author:  contrast_ [ Sun Sep 11, 2022 7:05 pm ]
Post subject:  cli345's cartoon filter as a native GEGL Filter.

Cli345 made most the graph I just ported as a native GEGL filter.

https://github.com/LinuxBeaver/GEGL-Photo-to-Cartoon-

Remember this goes in /gegl-0.4/plug-ins. Not Gimp's normal plugin folder. (tons of people are making this mistake). This filter has internal blend modes. HardLight, Multiply and an option for Color Removal.

Image
Image
Image

Cli345's other filter I ported is also here. (GEGL Pencil Sketch)
viewtopic.php?f=9&t=19928&hilit=pencil


Link to Cli345's original graph that this filter is mostly based on.
viewtopic.php?f=10&t=19463&start=20#p266181

Modified Graph I used.

#cli345's photo to cartoon filter
id=myStart

noise-reduction domain-transform n-iterations=5

difference-of-gaussians radius1=1.6  radius2=0.53
gimp:desaturate mode=value
levels in-low=0.007 in-high=0.009
invert-gamma rgb-clip


hard-light aux=[ ref=myStart hue-chroma lightness=1 chroma=3 ]
domain-transform
domain-transform
domain-transform
domain-transform
mean-curvature-blur iterations=4

Author:  Rod [ Mon Sep 12, 2022 12:38 am ]
Post subject:  Re: cli345's cartoon filter as a native GEGL Filter.

Thank you for this GEGL filter. I could not get the python filter to work in Gimp-2.10.32.It would load but error when i ran it. Not to mention the python dialog window is so tall i can't get to the execute button. I had to count tab hits. :hoh

Why we need scroll bars or tabs in these plugins when they have so many options. Or possibly add the ability to resize the dialog? :hehe

My play with your plugin. :bigthup :clap

Attachment:
Pencil-Sketch-GEGL_Cartoon_RD-2022-09-12_013344.jpg
Pencil-Sketch-GEGL_Cartoon_RD-2022-09-12_013344.jpg [ 277.61 KiB | Viewed 1820 times ]


Makes a nice pencil sketch filter all on it's own. Cartoon works great also.

Author:  Rod [ Mon Sep 12, 2022 1:09 am ]
Post subject:  Re: cli345's cartoon filter as a native GEGL Filter.

So i took that result and did a color to alpha on white. Then i was able to stroke the selected edges and paint the selection with a leaf brush. :)

Attachment:
Leaf-Dress-AND-Hat_RD-Girl-Walking-2022-08-20_013518.jpg
Leaf-Dress-AND-Hat_RD-Girl-Walking-2022-08-20_013518.jpg [ 183.05 KiB | Viewed 1816 times ]

Author:  Rod [ Mon Sep 12, 2022 3:06 am ]
Post subject:  Re: cli345's cartoon filter as a native GEGL Filter.

Just one more that started with the GEGL Photo To Cartoon filter. :bigthup

Gradient fill in the selection lines.

Attachment:
Girl-WalkingColor-Grasient_RD-2022-08-20_013518.jpg
Girl-WalkingColor-Grasient_RD-2022-08-20_013518.jpg [ 206.27 KiB | Viewed 1809 times ]

Author:  contrast_ [ Mon Sep 12, 2022 2:00 pm ]
Post subject:  Re: cli345's cartoon filter as a native GEGL Filter.

The version on my computer does not have overlay. it says "remove color" This is because the version I uploaded to Github was when I tested the overlay blend mode and removed it because it was 95% like hardlight. I will be pushing a cosmetic update that replaces overlay with remove color mode. This will have no feature changes.

I may even make it where gegl:pencil and this are one filter. (But that would confuse novices) as I would have to add a gaussian blur and one other thing for pencil mode.

Author:  contrast_ [ Mon Sep 12, 2022 3:19 pm ]
Post subject:  Re: cli345's cartoon filter as a native GEGL Filter.

The overlay blend mode now works and does an actual gegl:overlay but it has a extra setting called srgb=true to make it distinct as possible from gegl:hardlight. NOTE This filter may trigger an error and force you to navigate to
config/GIMP/2.10/filters/GimpGegl-gegl-photo2cartoon-config.settings
and delete GimpGegl-gegl-photo2cartoon-config.settings. This apparently is a consequence of updating a filter with an enum list.

grrrr.......

Author:  contrast_ [ Mon Sep 12, 2022 3:26 pm ]
Post subject:  Re: cli345's cartoon filter as a native GEGL Filter.

Rod wrote:
Thank you for this GEGL filter. I could not get the python filter to work in Gimp-2.10.32.It would load but error when i ran it. Not to mention the python dialog window is so tall i can't get to the execute button. I had to count tab hits. :hoh

Why we need scroll bars or tabs in these plugins when they have so many options. Or possibly add the ability to resize the dialog? :hehe

My play with your plugin. :bigthup :clap

Attachment:
Pencil-Sketch-GEGL_Cartoon_RD-2022-09-12_013344.jpg


Makes a nice pencil sketch filter all on it's own. Cartoon works great also.


I removed the pencil sketch ability as it is found in Gegl:pencil and gegl:pencil goes faster and has an additional blur option. I am thinking about giving pencil a white color overlay option but I am lazy. I could have made pencil and phototocartoon one filter but phototocartoon contains literally five domain smooths and that slows things down a lot.

Author:  Rod [ Tue Sep 13, 2022 3:24 am ]
Post subject:  Re: cli345's cartoon filter as a native GEGL Filter.

contrast_ wrote:
Rod wrote:
Thank you for this GEGL filter. I could not get the python filter to work in Gimp-2.10.32.It would load but error when i ran it. Not to mention the python dialog window is so tall i can't get to the execute button. I had to count tab hits. :hoh

Why we need scroll bars or tabs in these plugins when they have so many options. Or possibly add the ability to resize the dialog? :hehe

My play with your plugin. :bigthup :clap

Attachment:
Pencil-Sketch-GEGL_Cartoon_RD-2022-09-12_013344.jpg


Makes a nice pencil sketch filter all on it's own. Cartoon works great also.


I removed the pencil sketch ability as it is found in Gegl:pencil and gegl:pencil goes faster and has an additional blur option. I am thinking about giving pencil a white color overlay option but I am lazy. I could have made pencil and phototocartoon one filter but phototocartoon contains literally five domain smooths and that slows things down a lot.

I agree. Blur settings in any filter slows things down alot. ;)

Author:  cli345 [ Fri Sep 16, 2022 10:54 am ]
Post subject:  Re: cli345's cartoon filter as a native GEGL Filter.

Thanks, contrast_, good work! :)
Now, we have five versions of the "Comic Book" filter:
  • Filters -> Artistic -> Comic Book for 2.10
  • Filters -> Artistic -> Simple Cartoon
  • Filters -> G'MIC-Qt -> Artistic -> Comicbook
  • Filters -> Generic -> GEGL Graph... -> the preset into which you have copied the code of this
    (At first, in my mind, this version was just an approximation for illustrative purposes.)
  • Tools -> GEGL Operations -> Photo to Cartoon

Each one has advantages and drawbacks and gives a (slightly ?) different result. You have a choice :)

Author:  mahvin [ Tue Sep 20, 2022 1:36 am ]
Post subject:  Re: cli345's cartoon filter as a native GEGL Filter.

GMIC is the best version in my book. Just my opinion...

Author:  contrast_ [ Fri Sep 23, 2022 11:53 pm ]
Post subject:  Re: cli345's cartoon filter as a native GEGL Filter.

Custom Bevel, Color Lighting Fusion, Photo to Cartoon , Glow Stick and GEGL Effects have an emergency update.


If two filters have the same name of a blend mode enum list it will result in the blend mode switch option being hidden. Check these filters to make sure they have their blend mode switchers. Updating to the latest version solves the problem.

Page 1 of 1 All times are UTC - 5 hours [ DST ]
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/