Post all Gimp tutorials, tips and how-to's here
Wed Jun 23, 2021 10:29 am
Hello,
![Smile :)](./images/smilies/icon_smile.gif)
Here is a tutorial to learn the "GEGL graph" filter.
EDIT: For the motivations, you can read
this thread first.
EDIT (thanks to rich2005):
Warning: this filter doesn't make a single effect, but it enables you to program almost all effects and combine them.1) First steps:- Open an image
- Go to "Filters->Generic->GEGL graph
![menu.jpg](./download/file.php?id=52751&sid=deddcaa77cd5351b4736c2b0e02fa6ce)
- menu.jpg (42.83 KiB) Viewed 18322 times
- Click the "pipeline" box
![pipeline.jpg](./download/file.php?id=52752&sid=deddcaa77cd5351b4736c2b0e02fa6ce)
- pipeline.jpg (53.31 KiB) Viewed 18322 times
- Hit "ctrl-a" and the "delete" key
![emptyPipeline.jpg](./download/file.php?id=52753&sid=deddcaa77cd5351b4736c2b0e02fa6ce)
- emptyPipeline.jpg (31.1 KiB) Viewed 18322 times
- Write anything (for example, "sdfg")
- ...to be continued in the next post...
Wed Jun 23, 2021 10:39 am
- Look at below the "pipeline" box
![info.jpg](./download/file.php?id=52754&sid=deddcaa77cd5351b4736c2b0e02fa6ce)
- info.jpg (39.25 KiB) Viewed 18324 times
This part will be the most useful one (It's the info zone)
but, for now, it's not very useful : it just indicate that the "sdfg" operation doesn't exist
. - Delete "sdfg" and write "e"
![info2.jpg](./download/file.php?id=52755&sid=deddcaa77cd5351b4736c2b0e02fa6ce)
- info2.jpg (55.76 KiB) Viewed 18324 times
Now, it's more useful, it offers suggestions
. - We choose "gegl:edge". Note: you don't need to write "gegl:"
So, continue to write to obtain "edge" and look at the info zone for each character you type
![info3.jpg](./download/file.php?id=52756&sid=deddcaa77cd5351b4736c2b0e02fa6ce)
- info3.jpg (100.13 KiB) Viewed 18324 times
The info zone has disappeared and the "edge" effect is done
. - Congratulations, you have written your first GEGL graph.
Note: Some operations don't belong to GEGL. For these ones, you have to prefix the operation with "gimp:" (for example, "gimp:desaturate").
Have fun!
To be continued...
Thu Jun 24, 2021 9:56 am
2) How to add parameters:You wish to add parameters but you don't know which exist
![Confused :?](./images/smilies/icon_confused.gif)
: no problem
![Wink ;)](./images/smilies/icon_wink.gif)
.
- After "edge" write a blank space and write "aa=" (without any spaces between "aa" and "=").
![param1.jpg](./download/file.php?id=52760&sid=deddcaa77cd5351b4736c2b0e02fa6ce)
- param1.jpg (42.31 KiB) Viewed 18241 times
The info zone indicates all possible parameters (It calls them "properties")
. - We choose "algorithm". So replace "aa" by "algorithm"
![param2.jpg](./download/file.php?id=52761&sid=deddcaa77cd5351b4736c2b0e02fa6ce)
- param2.jpg (43.18 KiB) Viewed 18241 times
The info zone indicates all possible value for the "algorithm" parameter
. - We choose "differential". So, just after "=", write "differential" (without any spaces between "=" and "differential").
![param3.jpg](./download/file.php?id=52762&sid=deddcaa77cd5351b4736c2b0e02fa6ce)
- param3.jpg (34.14 KiB) Viewed 18241 times
The info zone has disappeared and the "edge algorithm=differential" effect is done
.
CAUTION: "id=blahblah" and "ref=blahblah" look like parameters and are written like parameters but they are NOT, they are special operations(We will see later their use).
(If you are very curious and cannot wait, "id=blahblah" is "save" and "ref=blahblah" is "retrieve")
Have fun!
To be continued...
Thu Jun 24, 2021 8:35 pm
I like the way you're teaching, by showing that the cat can walk on our keyboard and the result will be that we won't break anything but get help, is very nice
Fri Jun 25, 2021 1:04 am
Thanks cli345 for taking the time to put this together.
It's been added to our tutorial index.
Fri Jun 25, 2021 5:28 am
Thanks for your valuable feedback!
3) How to chain multiple effects:You simply list all the effects each in one line like this:
![chain.jpg](./download/file.php?id=52816&sid=deddcaa77cd5351b4736c2b0e02fa6ce)
- chain.jpg (36.41 KiB) Viewed 18186 times
Note: You don't have to put them into multiple lines. You may put them into a single line but separated by spaces (It's just less clear
![Wink ;)](./images/smilies/icon_wink.gif)
).
Note: We will see later that it's possible to get all intermediate stages back.
Have fun!
To be continued...
Sat Jun 26, 2021 1:42 am
Thanks for doing this tutorial. I find it very helpful.
Sat Jun 26, 2021 9:49 am
Thanks, nelo, for your valuable feedback!
4) How to save and retrieve any intermediate stage:To save an intermediate stage, simply add the special operation "id=chosenName" where the intermediate stage occurs.
For example:
![intermediate1.jpg](./download/file.php?id=52855&sid=deddcaa77cd5351b4736c2b0e02fa6ce)
- intermediate1.jpg (33.51 KiB) Viewed 18103 times
To retrieve an intermediate stage, simply add the special operation "ref=nameOfStageToRetrieve" where you want it to come back.
For example:
![intermediate2.jpg](./download/file.php?id=52856&sid=deddcaa77cd5351b4736c2b0e02fa6ce)
- intermediate2.jpg (34.22 KiB) Viewed 18103 times
This is a crazy example (since I discard "invert-gamma" result
![Shocked :shock:](./images/smilies/icon_eek.gif)
), but we will see useful examples later.
Have fun!
To be continued...
Sun Jun 27, 2021 12:07 pm
I'm curious as to what this plugin does.
Mon Jun 28, 2021 4:49 am
Excellent!
Thanks cli345 (out of curiosity, does cli in your nickname stand for "command line interface"?)
Mon Jun 28, 2021 5:49 am
PixLab wrote:Excellent!
Thanks cli345 (out of curiosity, does cli in your nickname stand for "command line interface"?)
Maybe, but I'm guessing it's derived from Claude and the French city of Lyon.
This looks interesting
Mon Jun 28, 2021 10:06 am
Thank you, mackenzieh, for your question.
Rich2005 has answered
here (Thanks, rich2005).
This diagram is aimed to explain my last (crazy) example:
![pipelineExplain1b.jpg](./download/file.php?id=52899&sid=deddcaa77cd5351b4736c2b0e02fa6ce)
- pipelineExplain1b.jpg (18.08 KiB) Viewed 10811 times
(EDIT: I've changed the diagram)
Mon Jun 28, 2021 6:40 pm
cli345 wrote:Thank you, mackenzieh, for your question.
Rich2005 has answered
here (Thanks, rich2005).
This diagram is aimed to explain my last (crazy) example:
pipelineExplain1.jpg
I think I get it now.
Tue Jun 29, 2021 10:13 am
5) How to combine multiple effects:Some operations (for example, "multiply", "subtract") enable you to combine
two results.
These operations accept a special parameter : "aux=[ ... ]" (No space around "=", a mandatory space after "[" and before "]").
For example, one of these operations is "subtract" (this operation does the same job as "subtract" layer mode).
In "GEGL graph", write:
- Code:
id=myStart
gaussian-blur
id=myBlur
ref=myStart
subtract aux=[ ref=myBlur ]
Notes:
- (When you've typed "aux=", the info zone says "aux" parameter doesn't exist (It's not true). But, when you've typed "[", the error disappears.)
- This GEGL graph does the same effect as this process:
- duplicate the layer
- apply a gaussian blur onto the upper layer
- set the mode of upper layer to "subtract"
- do "merge down" on the upper layer
- ("aux=[ blahblah ]" seems always accepted but, for most operations, it does not change anything.)
- This GEGL graph can be compacted to "id=myStart subtract aux=[ ref=myStart gaussian-blur ]"
Have fun!
To be continued...
Tue Jun 29, 2021 3:20 pm
I was just scratching my blockhead if it's possible to change layer modes somehow, having workflows that include stress, fattal and mantiuk filters with changed layer modes. This is fantastic information, now I can convert some of them into GEGL Graph one-clickers.
Thank you Claude.
Wed Jun 30, 2021 2:23 am
great stuff, thanks!
Thu Jul 01, 2021 11:41 am
Thanks, for your feedback!
This diagram is aimed to explain my last example:
![pipelineExplain2.jpg](./download/file.php?id=52998&sid=deddcaa77cd5351b4736c2b0e02fa6ce)
- pipelineExplain2.jpg (26.77 KiB) Viewed 10734 times
Fri Jul 02, 2021 8:40 am
The last diagram can be summarized by:
![pipelineExplain2b.jpg](./download/file.php?id=53029&sid=deddcaa77cd5351b4736c2b0e02fa6ce)
- pipelineExplain2b.jpg (13.06 KiB) Viewed 10695 times
Wed Jul 07, 2021 9:39 am
6) PracticeCode this "GEGL graph":
![practice1.jpg](./download/file.php?id=53194&sid=deddcaa77cd5351b4736c2b0e02fa6ce)
- practice1.jpg (38.27 KiB) Viewed 10615 times
Here are loose fragments for easy copy-pastes:
- Code:
noise-reduction
bilateral-filter edge-preservation=100 blur-radius=12
difference-of-gaussians radius1=0.66 radius2=0.22
levels in-low=0.001 in-high=0.01
gimp:desaturate mode=value
invert
antialias
hue-chroma chroma=20 lightness=10
multiply
Warning: At each letter typed, the whole effect is recomputed. So, it's better to write in a text editor and copy-paste onto the "GEGL graph" window.
Have fun!
To be continued...
Wed Jul 07, 2021 1:07 pm
cli345 wrote:Warning: At each letter typed, the whole effect is recomputed. So, it's better to write in a text editor and copy-paste onto the "GEGL graph" window.
Have fun!
To be continued...
Good hint, I disable preview when testing longer chain of effects and use a small image.
Few times when editing a longer chain somewhere in between, it got stuck and I had to click the GEGL Graph exit button which resulted in crash.
Practice result
![GEGL-Practice.png](./download/file.php?id=53206&sid=deddcaa77cd5351b4736c2b0e02fa6ce)
- GEGL-Practice.png (445.82 KiB) Viewed 10601 times
Powered by phpBB © phpBB Group.
phpBB Mobile / SEO by Artodia.