Welcome, Guest
You have to register before you can post on our site.

Username
  

Password
  





Search Forums

(Advanced Search)

Forum Statistics
» Members: 5,146
» Latest member: cjel
» Forum threads: 7,820
» Forum posts: 42,466

Full Statistics

Latest Threads
re-coloured pixels hide c...
Forum: Extending the GIMP
Last Post: programmer_ceds
Yesterday, 05:30 PM
» Replies: 1
» Views: 112
Wavelet-decompose doing m...
Forum: General questions
Last Post: JohnWilliams
Yesterday, 07:46 AM
» Replies: 9
» Views: 5,246
Smudge tool not working
Forum: General questions
Last Post: sallyanne
Yesterday, 12:51 AM
» Replies: 3
» Views: 219
Thank you for Gimp
Forum: Watercooler
Last Post: Sampollyt
02-25-2026, 12:38 PM
» Replies: 0
» Views: 106
RapidRAW
Forum: Other graphics software
Last Post: denzjos
02-25-2026, 07:40 AM
» Replies: 3
» Views: 1,014
Hiding Unwanted System Fo...
Forum: Extending the GIMP
Last Post: rich2005
02-24-2026, 10:05 AM
» Replies: 1
» Views: 210
Version Issue
Forum: General questions
Last Post: rich2005
02-23-2026, 09:40 PM
» Replies: 1
» Views: 242
GIMP 3 Python Enums: Defi...
Forum: Extending the GIMP
Last Post: MrsP-from-C
02-23-2026, 08:27 PM
» Replies: 6
» Views: 389
Odd problem with GIMP 3.0...
Forum: General questions
Last Post: cjsmall
02-22-2026, 08:09 PM
» Replies: 4
» Views: 458
Anyone working on video g...
Forum: Watercooler
Last Post: connag
02-22-2026, 07:48 PM
» Replies: 3
» Views: 2,111

 
  1st plugin attempt - save jpeg question
Posted by: nmw01223 - 01-18-2026, 02:47 PM - Forum: Extending the GIMP - No Replies

I am embarking on my 1st (python) plugin using GIMP 3. I'm a long term (basic) Photoshop user and have a lot of software design experience - but virtually no GIMP experience and zero python experience. So, it's a bit of a learning curve. 

What I'm doing is pretty simple, replicating something I used to do with Photoshop using VB (OLE) automation. Basically, a batch process - need to point to a source directory containing images of various types and resolutions (TIF, PSD, JPG etc), then to load them one by one, perform some basic (automatic) changes, and write them out one by one as JPEGs  to a different directory.

I've got the basic plugin shell going, with a dialog to select directories etc, define the automatic changes and so on, and it seems to work fine.

I think I can see how to get the source filenames using scandir() imported from os. Now looking at loading the files and writing the JPEGs. I assume I can use Gimp.file_load() to load an image.

But, when one writes a JPEG, there are usually some parameters - the JPEG level for file compression to start with. I cannot see any function for doing that. I found Gimp.file_save(run_mode, image, file, options), but it says options isn't used. I really don't want it to pop up a dialog to set these things.

So my basic questions are, is file_load() the right way to load an image, and how do I save a JPEG setting all necessary parameters programmatically?

Print this item

  Desk Top Icon for shortcut to GIMP
Posted by: Ronald - 01-18-2026, 05:00 AM - Forum: Windows - Replies (1)

Newbe here! Smile Could someone tell me how to install a GIMP shortcut on my Windows 11 desktop ? thanks!

Print this item

  Gimp 3.0.6 appimage - 'buntu 24.04 / Mint 22.3 only
Posted by: rich2005 - 01-16-2026, 06:06 PM - Forum: Alternate Gimp packagings - Replies (13)

A bit restricted but might be of use.

A cut down appimage that relies on system python 3 installation and qt5 (for the gmic plugin)

https://u.pcloud.link/publink/show?code=...sLD8CXBYh7    43 MB

and for the gimp_gmic_qt plugin https://u.pcloud.link/publink/show?code=...wBHYijirC7 5 MB Unzip and put the folder in your Gimp user profile plug-ins folder.

Print this item

  'The Windows 11 Crisis' Video
Posted by: Tas_mania - 01-16-2026, 10:22 AM - Forum: Watercooler - Replies (3)

Even though I haven't used Windows for years I watched this because I was interested in the so-called 'crisis'. It looks like a user revolt over AI forcing users to subscribe to what AI wants.





Print this item

  After Mint update I can no longer name files to save
Posted by: CtrlAltDel - 01-16-2026, 01:39 AM - Forum: General questions - Replies (4)

Rich,

I thought I would direct this post specifically to you since you have provided me with Gimp 2.10.38 and Gimp 3.0.6 AppImages and I thought you may find this interesting.

After updating from Mint 22.2 to Mint 22.3 Cinnamon, neither of my Gimp's will allow files to be renamed or named when trying to save as or export as. 

[Image: YCjwq1c.jpeg]

As an example, in the image above, I'm unable to backspace at all.  It's like the keyboard is dead.  All other programs that I want to rename something in works though, so Gimp seems to be singularly affected.


It has to be related to the update of Mint because that is precisely the moment this issue arose but, I thought I would just check here with you to definitely rule out it being a Gimp problem before I head over to the Mint forum.

Print this item

  G'Mic-Qt in GIMP 3.2.0-RC1/2 error
Posted by: denzjos - 01-12-2026, 04:45 PM - Forum: Windows - Replies (2)

When using G'Mic-Qt in GIMP 3.2.0-RC1 and RC2, I get this message. When I click OK on the error messages, G'Mic-Qt is activated and works fine. (sorry error in dutch Blush )
   

Print this item

  Best way to recolor this image
Posted by: IndiePubber - 01-11-2026, 05:02 AM - Forum: General questions - Replies (12)

I'll be using the attached image for the background of the cover for the next novel I'm indie publishing. I want to switch the colors so the white infill areas are a certain shade of red, the dark timbers are shades of pinkish white, and the windows are something in between--- not all the same color, but a range reflecting the highlights and shadows of the original picture.

   

I've learned that Colors ---> Maps ---> Color Exchange might work for me. I've figured out that I can't select the From Color until I've turned off the alpha channel on the image. 

But when I select the From Color, choose the To Color, and click OK, nothing happens. The photo doesn't change, even though the Edit menu gives me the option to undo the Color Exchange.

I prefer to work on my older ThinkPad touchscreen laptop where I run GIMP 2.8 on Windows 7. I also have a Windows 10 PC with GIMP 3.04. As another test, I used it to try Color Exchange on this Fachwerk photo. But again, when I click OK, I see no change. And again, the Edit menu tells me the exchange was made.

It's the same with other images I've tried.

Given all this, I have two questions:

1. Is Color Exchange the best way to do what I want here?

2. If it is, what am I failing to do, that I can't see any change in 2.8 or in 3.04? Is there another step I need to take to complete the process?

Thanks in advance.

Print this item

  Help with making this effect look more realistic
Posted by: Tygra - 01-09-2026, 09:57 PM - Forum: General questions - Replies (8)

Hi guys,

I am trying create a similar effect on my predator image (the first image) as it is in the photograph from the movie (the second image), where there are link blue sparks of electricity. I know it looks very different at the moment, but I am trying to make it look more realistic. At the moment the blue sparks on the first image looks like it is just pasted over the top of predator, as opposed to making it look like it is actually on his body.

Do you guys know what technique I could use to make it look like the blue sparks are actually on his body?

Many thanks.



Attached Files Thumbnail(s)
       
Print this item

  Installing in a secure environment
Posted by: ThecknoDecker - 01-09-2026, 06:18 PM - Forum: Windows - Replies (2)

We want to install Gimp at our office. 

But we are looking for a way to block the installation of plug-ins by our users.

The objective being that the IT Dept, will verify the plugins and the security risks of them before deploying to each user.

I haven't seen a way to block the installation of plugins by users. Espacially since they can always go and say it's in this or that folder (so finding one they have rights to).

Thanks,

Print this item

Python Photobooth "look" - python script
Posted by: chlowden007 - 01-09-2026, 07:42 AM - Forum: Extending the GIMP - Replies (7)

Hello
I asked Gemini GPT about how to replicate a colour chemical photobooth look in GIMP. Gemini explained the photobooth history, different lenses and chemical approaches and eventually wrote me a python script that creates the look.
Of course, the python script looks the part to an neophyte such as myself, but does not work either in python3 or Gimp python or as a filter. It does not show in GEGL either.
(I have yet to get a GPT sourced python script that works off the bat, so dev still have a career in front of them).
The funny thing is, the every time I ask the GPT to correct the script, it finds an "error" to correct, but none of these corrections ever make the code work.
The primary issue is that when I run the script in fu-script, I get loads of indentation error! Python indentation drives me crazy.
Therefore ... Does anyone know if there is a working "photobooth" GIMP script?
Can anyone help me debug this script for GIMP 3 linux  please ?

Code:
#!/usr/bin/python
# -*- coding: utf-8 -*-

import sys
import gi
import datetime

try:
   gi.require_version('Gimp', '3.0')
   gi.require_version('Gegl', '0.4')
   from gi.repository import Gimp, Gegl, GObject, GLib
except ValueError, e:
   sys.exit(1)


def apply_schneider_look(image, drawable):
   """Applies optical and chemical effects."""

   pdb = Gimp.get_pdb()

   # 1. Mirror

   drawable.transform_flip_simple(Gimp.OrientationType.HORIZONTAL,
                                  True, 0)

   # 2. Schneider Optical Effects
   # We use Gimp.ValueArray.new(count) for GIMP 3 compatibility

   dist_args = Gimp.ValueArray.new(3)
   dist_args.insert(0, GObject.Value(Gimp.Drawable, drawable))
   dist_args.insert(1, GObject.Value(GObject.TYPE_STRING,
                    'gegl:lens-distortion'))
   pdb.run_procedure('gimp-drawable-edit-gegl-config', dist_args)

   bloom_args = Gimp.ValueArray.new(3)
   bloom_args.insert(0, GObject.Value(Gimp.Drawable, drawable))
   bloom_args.insert(1, GObject.Value(GObject.TYPE_STRING, 'gegl:bloom'
                     ))
   pdb.run_procedure('gimp-drawable-edit-gegl-config', bloom_args)

   # 3. Chemical Color Shift

   cb_args = Gimp.ValueArray.new(11)
   cb_args.insert(0, GObject.Value(Gimp.Drawable, drawable))
   cb_args.insert(1, GObject.Value(GObject.TYPE_DOUBLE, -0.15))
   cb_args.insert(2, GObject.Value(GObject.TYPE_DOUBLE, 0.0))
   cb_args.insert(3, GObject.Value(GObject.TYPE_DOUBLE, 0.10))
   cb_args.insert(4, GObject.Value(GObject.TYPE_DOUBLE, 0.0))
   cb_args.insert(5, GObject.Value(GObject.TYPE_DOUBLE, 0.0))
   cb_args.insert(6, GObject.Value(GObject.TYPE_DOUBLE, 0.0))
   cb_args.insert(7, GObject.Value(GObject.TYPE_DOUBLE, 0.10))
   cb_args.insert(8, GObject.Value(GObject.TYPE_DOUBLE, 0.0))
   cb_args.insert(9, GObject.Value(GObject.TYPE_DOUBLE, -0.25))
   cb_args.insert(10, GObject.Value(GObject.TYPE_BOOLEAN, True))
   pdb.run_procedure('gimp-drawable-color-balance', cb_args)

   # 4. Silver Halide Grain

   grain_args = Gimp.ValueArray.new(3)
   grain_args.insert(0, GObject.Value(Gimp.Drawable, drawable))
   grain_args.insert(1, GObject.Value(GObject.TYPE_STRING,
                     'gegl:noise-rgb'))
   pdb.run_procedure('gimp-drawable-edit-gegl-config', grain_args)


def photobooth_main_proc(
   procedure,
   run_mode,
   image,
   drawables,
   args,
   data,
   ):
   Gimp.context_push()
   image.undo_group_start()

   # Constants

   (STRIP_W, STRIP_H) = (600, 1800)
   (MARGIN, FRAME_H) = (40, 400)

   new_image = Gimp.Image.new(STRIP_W, STRIP_H, Gimp.ImageBaseType.RGB)

   bg_color = Gimp.RGB()
   bg_color.set_parse('#F9F7F2')
   bg_layer = Gimp.Layer.new(
       new_image,
       'Paper Base',
       STRIP_W,
       STRIP_H,
       Gimp.Precision.U8_GAMMA,
       100,
       Gimp.LayerMode.NORMAL,
       )
   new_image.insert_layer(bg_layer, None, 0)
   Gimp.context_set_background(bg_color)
   bg_layer.fill(Gimp.FillType.BACKGROUND)

   y_offset = MARGIN
   for i in range(min(len(drawables), 4)):
       source_layer = drawables[i]
       new_frame = Gimp.Layer.new_from_drawable(source_layer,
               new_image)
       new_image.insert_layer(new_frame, None, -1)

       apply_schneider_look(new_image, new_frame)

       target_w = STRIP_W - MARGIN * 2
       scale_ratio = target_w / new_frame.get_width()
       new_frame.scale(target_w, int(new_frame.get_height()
                       * scale_ratio), True)
       new_frame.set_offsets(MARGIN, y_offset)
       y_offset += FRAME_H + 15

   # Mechanical Date Stamp

   stamp_color = Gimp.RGB()
   stamp_color.set_parse('#B22222')
   Gimp.context_set_foreground(stamp_color)
   date_str = datetime.datetime.now().strftime('PHOTO-ME - %d %b %Y'
           ).upper()

   # Text Layer logic for GIMP 3

   stamp_layer = Gimp.text_fontname(
       new_image,
       None,
       0,
       0,
       date_str,
       0,
       True,
       18,
       'Sans-Serif',
       )
   if stamp_layer:
       stamp_layer.transform_rotate_simple(Gimp.OrientationType.VERTICAL,
               True, 0, 0)
       stamp_layer.set_offsets(STRIP_W - 35, STRIP_H - 450)
       stamp_layer.set_opacity(70)

   Gimp.Display.new(new_image)
   image.undo_group_end()
   Gimp.context_pop()
   Gimp.displays_flush()

   return procedure.new_return_values(Gimp.PDBStatusType.SUCCESS,
           GLib.Error())


class PhotoboothPro(Gimp.PlugIn):

   def do_query_procedures(self):
       return ['python-fu-photobooth-pro']

   def do_create_procedure(self, name):
       procedure = Gimp.ImageProcedure.new(self, name,
               Gimp.PDBProcType.PLUGIN, photobooth_main_proc, None)
       procedure.set_image_types('RGB*')
       procedure.set_documentation('Schneider Photobooth Pro',
                                   'Full analog strip recreation',
                                   name)
       procedure.set_menu_label('Schneider Photobooth Pro...')
       procedure.add_menu_path('<Image>/Filters/Artistic')
       procedure.set_attribution('Gemini', 'Gemini', '2026')
       return procedure


Gimp.main(PhotoboothPro.__gtype__, sys.argv)

Print this item