It is currently Tue Jul 02, 2024 3:00 am


All times are UTC - 5 hours [ DST ]



Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: GEGL command line and layer modes?
PostPosted: Tue Jul 11, 2023 6:24 am  (#1) 
Offline
New Member

Joined: Jul 10, 2023
Posts: 1
I am just getting started with gegl. I was pleased to read that there is a command line gegl tool, called, oddly enough, gegl :-)

I'm having some success with gegl, but there are some concepts I'm having trouble understanding.

First, am I going to be able to set layer modes (such as blend mode)? If found another post that uses 'gimp:layer-mode' but this doesn't seem to be supported by the gegl command-line tool.

I did notice a layer operation in the gegl namespace, which has properties for 'composite-op', 'opacity', 'x', 'y', 'scale', and 'src'. But this doesn't include the layer blend mode.

Examples..

% gegl LakeviewWithSunrise.jpg -o z.jpg -- gimp:layer layer-mode=multiply
Error: No such op 'gimp:layer'

% gegl LakeviewWithSunrise.jpg -o z.jpg -- gegl:layer layer-mode=multiply
Error: gegl:layer has no layer-mode property, properties: 'composite-op', 'opacity', 'x', 'y', 'scale', 'src',


Share on Facebook Share on Twitter Share on Orkut Share on Digg Share on MySpace Share on Delicious Share on Technorati
Top
 Post subject: Re: GEGL command line and layer modes?
PostPosted: Tue Jul 11, 2023 6:30 pm  (#2) 
Offline
GimpChat Member
User avatar

Joined: Nov 04, 2015
Posts: 1365
The command line version of gegl cannot access Gimp operations directly. It's a 'stand-alone' program.

The gegl operations list is here.

On linux these are the commands to use first.
sudo apt install gegl
gegl --list-all
gegl --info gegl:crop (this gives the options for the crop operation)

My gegl hue chroma script is at comment #36 here.
It's a simple script that rotates the hue chroma values over 35 frames.


Top
 Post subject: Re: GEGL command line and layer modes?
PostPosted: Fri Jul 14, 2023 11:12 am  (#3) 
Offline
GimpChat Member
User avatar

Joined: Oct 31, 2020
Posts: 1455
I recommend you use Gimp's GEGL Graph for this and not GEGL Command line as it has more options; such as Gimp layer modes.

Gimp only blend modes "gimp layer-mode layer-mode=" are not found in stand alone GEGL but they are in Gimp's GEGL Graph and do work in Gimp plugins and I use them because they are better then the default GEGL blend modes.

GEGL Layer which you cited should be ignored in favor of composers.

A composer is a BLENDMODEHERE aux=[] with optional image bookmarks called id and ref. ID is the bookmark and REF calls the bookmark. This is how images are fused with blend modes in GEGL

Here are list of GEGL Only blend modes if you insist on using the cli. Opacity dictates the opacity of the blend mode.

NORMAL BLEND MODE
id=namehere over aux=[ ref=namehere content_inside_blend_mode opacity value=1 ]

MULTIPLY BLEND MODE
id=namehere multiply aux=[ ref=namehere content_inside_blend_mode opacity value=1 ]

SCREEN BLEND MODE
id=namehere screen aux=[ ref=namehere content_inside_blend_mode opacity value=1 ]


OVERLAY BLEND MODE
id=namehere overlay aux=[ ref=namehere content_inside_blend_mode opacity value=1 ]

COLOR DODGE BLEND MODE (like dodge)
id=namehere color-dodge aux=[ ref=namehere content_inside_blend_mode opacity value=1 ]

SOFT LIGHT BLEND MODE
id=namehere soft-light aux=[ ref=namehere content_inside_blend_mode opacity value=1 ]

ADD BLEND MODE (addition clone)
id=namehere add aux=[ ref=namehere content_inside_blend_mode opacity value=1 ]


HARDLIGHT BLEND MODE
id=namehere hard-light aux=[ ref=namehere content_inside_blend_mode opacity value=1 ]

PLUS BLEND MODE (like Gimp's addition but not exactly the same)
id=namehere plus aux=[ ref=namehere content_inside_blend_mode opacity value=1 ]

REPLACE BLEND MODE
id=namehere src aux=[ ref=namehere content_inside_blend_mode opacity value=1 ]

ALPHA LOCK LIKE BLEND MODE SET TO NORMAL
id=namehere src-over aux=[ ref=namehere content_inside_blend_mode opacity value=1 ]


ALPHA LOCK LIKE BLEND MODE SET TO REPLACE
id=namehere src-atop aux=[ ref=namehere content_inside_blend_mode opacity value=1 ]


ERASE BLEND MODE
id=namehere xor aux=[ ref=namehere content_inside_blend_mode opacity value=1 ]


BEHIND BLEND MODE
id=namehere dst-over aux=[ ref=namehere content_inside_blend_mode opacity value=1 ]


MAKE INVISIBLE BLEND MODE (hides content but does not remove it from memory)
id=namehere dst aux=[ ref=namehere content_inside_blend_mode opacity value=1 ]



I hope this GEGL blend mode list helps.

GEGL Layer is useful for Image file uploads but not blending.


Top
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC - 5 hours [ DST ]


   Similar Topics   Replies 
No new posts How do you run GIMP from the command line?

1

No new posts Shortcuts to 2.10 documentation re: Layer & Layer-group modes

0

No new posts Attachment(s) G'MIC> Pattern> Strip command line?

2

No new posts Calling GIMP Plug-in From Command Line - on Windows

0

No new posts Attachment(s) Experimenting with layer modes

6



* Login  



Powered by phpBB3 © phpBB Group