Interactive luminosity masks for GIMP 3

I’ve updated my luminosity masking plugin for GIMP 3. It’s a complete rewrite, and interactive. I approached the rewrite with simplicity, ease of use, and obviousness in mind.

How it works: You choose from among 3 variations each of lights, midtones, or darks - you see a live preview as you choose. Then you fine tune the mask interactively with a live view, using a fine tuning dialog that applies levels as you wish. You can play around, reset, and restart the process. Finally it adds a luminosity mask layer with the luminosity mask attached.

It’s supported for GIMP 3 in Linux and Windows. As for macOS, you’re welcome to try it, but given the limitations of macOS support for GTK dialogs, I can’t support it on that OS.

I’ll record a tutorial of course. Even so, I hope it’s self-explanatory as you use it.

It’s available in the following languages:

Dutch (Nederlands)
English (English)
French (Français)
German (Deutsch)
Italian (Italiano)
Hungarian (Magyar)
Japanese (日本語)
Polish (Polski)
Portuguese (Português)
Spanish (Español)
Ukrainian (Українська)
Chinese (Simplified) (简体中文)
Chinese (Traditional) (繁體中文)

The plugin detects the language you’re running GIMP in, and adjusts to it.

You can read more about the plugin and download it here:

https://www.chuckhenrich.com/gimp-interactive-luminosity-masks

This release is version 1.0 of the plugin. I’d appreciate any and all feedback!

7 Likes

Hi!
Very impressive!

1 Like

Thanks Yasuo!

I’ve updated the installation instructions - previously they referred to my frequency separation plugin by mistake. Updated instructions are here:

Apologies to anyone who was confused by the error!

2 Likes

Hi,

your plugin doesn’t work at all in Linux … is it tested ? there are multiple problems … it’s hardocded to version 3.0 (so doesn’t work in 3.1 or 2.x), python script is NOT executable in Linux since it contains windows end of the lines, other text files in the subfolders too …

I’ve spent with it now quite some time and … pfff

Can you please kindly look into your plugin ?

thank you

In my environment (Kubuntu 24.02 + GIMP3.06), it works fine.
To help the author, please show your error messages using verbose mode.

And any python scripts for GIMP3.0 cannot work in GIMP2.x.

1 Like

Hello @sigsegv111

I believe you are confused.

There are two versions of my luminosity mask plugin, one for GIMP 2 and one for GIMP 3. If you try to run the GIMP 3 version in GIMP 2, it will not work. The GIMP team have fundamentally changed how plugins work in GIMP 3, so GIMP 2 plugins are not compatible with GIMP 3 and vice versa.

In the blog post where I introduce the interactive luminosity mask plugin for GIMP 3, I mention that there is also a different plugin for GIMP 2:

It sounds like you may be using GIMP 2. In that case, download my luminosity mask plugin for GIMP 2 and try again:

https://www.chuckhenrich.com/gimp-luminosity-masks-easy/

Follow the installation instructions in that blog post.

I would be surprised if there are Windows end of line characters in the python file, but even if there are, they make no difference. Python’s tokenizer normalizes line endings. So a .py file with Windows-style endings runs fine on Linux and macOS.

The other text files in the subfolders are translation files. Including those files in that format in that specific folder structure is an industry standard way to deliver localised software.

My interactive luminosity mask plugin for GIMP 3 does not work in the current development version of GIMP 3.1.x. I won’t do any testing in GIMP 3.1.x while that version is still in development. As I mentioned in a different thread:

It’s way too early to be updating anything for 3.1.x because that upcoming version is very much a work in progress. For example, the Windows build is missing key libraries …

Generally it’s only a good idea to start testing extensions/plugins/etc against a release candidate of any software. A 3.1 RC is quite a bit in the future.

It is unfortunate that you spent “quite some time” trying to make something work that cannot work, because you did not read the documentation. In future, you will have better experiences if you RTFM, whether for my plugins or any other software.

I hope the information in this reply helps you.

One last thing: your dismissive tone (“pfff”) is not appropriate.

You’re welcome.

please don’t be that selective and definitely don’t be touchy … maybe there’s some language barrier (from my side of course) but my message also contained

I’d love to say that this doesn’t violate normal constructive communication in kind of familiar and semi-friendly manner between two interested people on opensource related forum … It was not meant any unfriendly or anything alike and it really grieves me to hear so, so please accept my apologize if my “pfff” offended you … It was meant instead as in kind of friendly and familiar tone

> unzip -p interactive-luminosity-masks-v3.zip interactive-luminosity-masks-v3/interactive-luminosity-masks-v3.py | head -1 | perl -ne 'printf("yes, there are\n") if m@\r$@'
yes, there are

additionally, just for safe to be on the same page … I’ve been discussing the topic in this thread originally

++

and @yasuo also maintains a great plugin doing the same or similar in very nice manner … FYI

GIMP 3.2 RC2
Querying plug-in: ‘C:\Users\zbign\AppData\Roaming\GIMP\3.2\plug-ins\interactive-luminosity-masks-v3\interactive-luminosity-masks-v3.py’
Traceback (most recent call last):
File “C:\Users\zbign\AppData\Roaming\GIMP\3.2\plug-ins\interactive-luminosity-masks-v3\interactive-luminosity-masks-v3.py”, line 48, in
gi.require_version(‘Rsvg’, ‘2.0’)
File “C:\Program Files\GIMP 3.2\lib\python3.12\site-packages\gi_init_.py”, line 132, in require_version
raise ValueError(f"Namespace {namespace} not available")
ValueError: Namespace Rsvg not available