Apply Color Presets using command line
essembeh opened this issue · 5 comments
Hi
I've been using Gimp and Gmic plugin for a while now and I'm looking for a way to automatize applying filter to many photos with a shell script.
The filters I want to apply are the "Colors/Color Presets", lets's say for the example "Cinematic Travel/Warm Teal"
How can I apply it with a command line, using gmic
directly?
Is there a way to customize the configuration values (contrast, gamma, hue ...) of the filter ?
Thanks
There is a button Copy command to clipboard that can help you for that.
Select your filter, tune your parameters, then press this button.
Now you can paste the corresponding G'MIC command in a shell command to apply it on multiple images.
In your example, I get:
$ gmic ~/work/img/*.jpg fx_color_presets 4,1,1,1,1,30,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,512,100,0,0,0,0,0,0,2,50,50,"0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0"
Hi
Thank you so much @dtschump, I never saw this button until now :)
Exactly what I was looking for 👍
I think I was too fast closing this issue ...
Unfortunatly @dtschump the command you shared does not work here ... any idea?
$ gmic *.JPG fx_color_presets 4,1,1,1,1,30,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,512,100,0,0,0,0,0,0,2,50,50,"0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0"
[gmic]./ Start G'MIC interpreter (v.3.3.1).
[gmic]./ Input file 'DSC_5360.JPG' at position 0 (1 image 4288x2848x1x3).
[gmic]./ Input file 'p' at position 1
[gmic]./ *** Error *** Unknown command or filename 'p'; did you mean '%'?
It seems your issue is not related to the fx_color_presets
command.
What happen if you replace *.JPG
by a single filename ?
I agree @dtschump
I think it might be a problem from NixOS (my Linux distribution).
I found this thread and the problem looks similar.
Let me close this issue since I found a solution for my question 👍