G'MIC 2.9.9: Specialization of `+custom_command`

News about this:

  • It’s not possible to define a +command specialization without the corresponding command and still be able to invoke command (without the +). In that case, it is just equivalent to invoking +command.

This solves a problem we had in previous versions of G’MIC for custom commands that were designed to insert a new image in the image list (e.g. clut or palette).
The problem was the following:

$ gmic sp lena +clut summer

duplicated the image lena, while

$ gmic sp lena clut summer

did not, but was not really in line with the G’MIC command philosophy that said +command inserts a new image while command just acts in place.

Now, defining the command clut as:

+clut : 
   # Code of command 'clut' here.

solves this problem, and

$ gmic sp lena +clut summer

just inserts the new clut image at the end of the list, without duplicating ‘lena’.

I’ve posted new pre-release binaries for Ubuntu 20.04 and Windows, this morning.