Welcome, Guest |
You have to register before you can post on our site.
|
Latest Threads |
Is there any version wher...
Forum: Older Gimp versions (2.8, 2.6....)
Last Post: rich2005
5 hours ago
» Replies: 1
» Views: 221
|
How do I uninstall GIMP 3...
Forum: Linux and other Unixen
Last Post: Ofnuts
6 hours ago
» Replies: 1
» Views: 79
|
AI Gimp Plugins
Forum: Watercooler
Last Post: merlilderman
Yesterday, 04:16 PM
» Replies: 21
» Views: 68,256
|
How to make a watermark o...
Forum: General questions
Last Post: kyolim
09-13-2025, 10:05 PM
» Replies: 5
» Views: 14,187
|
Linux command that does e...
Forum: Other graphics software
Last Post: rich2005
09-13-2025, 06:06 PM
» Replies: 1
» Views: 482
|
reliable Gimp 2.10.38 dow...
Forum: Older Gimp versions (2.8, 2.6....)
Last Post: denzjos
09-13-2025, 05:20 PM
» Replies: 2
» Views: 388
|
Batch Color Saturation
Forum: Extending the GIMP
Last Post: rich2005
09-13-2025, 07:53 AM
» Replies: 15
» Views: 12,075
|
Photo play-time
Forum: Gallery
Last Post: Ofnuts
09-13-2025, 07:32 AM
» Replies: 24
» Views: 21,906
|
BIMP plugin for GIMP 3.10
Forum: Extending the GIMP
Last Post: firefly
09-12-2025, 11:53 PM
» Replies: 2
» Views: 741
|
pl_stroke_arrows GIMP 3.0...
Forum: Extending the GIMP
Last Post: Scallact
09-12-2025, 04:03 PM
» Replies: 0
» Views: 389
|
|
|
Faking an undo step for functions that aren't undoable in Gimp |
Posted by: inkdolls - 09-15-2024, 08:40 PM - Forum: Scripting questions
- Replies (2)
|
 |
I intended to make this a question, but I figured out a few ways to do it, so I'm posting in case someone ever comes across this and only finds some very old unanswered questions online.
Some low level Python methods for Gimp, like get_pixel_rgn() are not undoable. For exampe, if I create a small 24 bit image, I can make the first row red, by typing this in the Python console, but then it can't be undone:
Code:
GIMP 2.6.12 Python Console
Python 2.7.18 (default, Jan 31 2024, 16:23:13)
[GCC 9.4.0]
➤> layer = gimp.image_list()[0].layers[0] # Newly created image.
➤> r = layer.get_pixel_rgn(0, layer.width, 0, 1) # First row.
➤> r[0:layer.width,0] = '\xff\x00\x00'*layer.width # Fill with red.
➤> layer.update(0, 0, layer.width, 1)
➤>
I wrote a plugin that is notably faster using this (obsolete) function, but I want to publish it and it's embarrassing that it can't be undone. So I need to simulate that an undo step was pushed into the stack:
Code:
image.undo_group_start() #Make the plugin's name appear in the undo history dialog.
pdb.gimp_brightness_contrast(drawable, 0, 0) # This does nothing, but a full image is stored.
image.undo_group_end() # Doesn't matter if the plugin has even started.
Some other things I've tried:
Creating a selection and deselecting it. Adds an undo state, but doesn't modify the image at all, so the changes to the image remain when trying to undo.
Copying and pasting the whole layer into itself. It works, but a very discocerting pop up of "Copied pixels to the clipboard" could appear if there is not an error console open.
Duplicating the layer and merging it down. This always adds an alpha channel, the original layer might not have one.
I guess I'll use the dummy "brightness" tool or something similar unless someone already has or can come up with a more elegant answer.
|
|
|
Batch Numbering Images |
Posted by: gmpuser - 09-15-2024, 07:55 PM - Forum: General questions
- Replies (7)
|
 |
Is there a way to add text/watermark to a batch of images? I want to use a kind of counter tool to add text starting from 1 and counting upwards:
1
2
3
...
10
11
...
99
100
101
I would also need to adjust the font including size and style.
Thank you for any help that can be provided.
|
|
|
Image Analyzer |
Posted by: denzjos - 09-10-2024, 12:31 PM - Forum: Other graphics software
- No Replies
|
 |
Old graphic freeware with simple graphic manipulation tools but some are interesting to use. The program is presented as follows : Image Analyzer is a simple but surprisingly effective utility for the advanced analysis, editing, and optimization of images.
Download link :
https://meesoft.com/Analyzer/
Detailed explanation :
https://meesoft.com/Analyzer/help.htm
Some interesting filters :
Operations / Filters / Warp (deformation correction with 4 clicks)
Operations / Color Correction / Color tone adjustment (many color ajustment options)
Operations / Color Correction / CLAHE (HDR)
Operations / Color Correction / Laplacian pyramid filter (many adjustment options)
Operations / Color Correction / Color mapper (Presets ' Zero point' / use slider)
|
|
|
PNG data without saving to file? |
Posted by: nchen - 09-09-2024, 08:44 PM - Forum: General questions
- Replies (3)
|
 |
Hello,
Is there a way to convert a layer to PNG data, and convert PNG data to a layer, without exporting to a file?
I am trying to send a layer to a local server that accepts base64 encoded PNG data, receive base64 encoded PNG data, then convert that data back into a layer.
My current process is as follows:
> Save layer as PNG (pdb.gimp_file_save)
> Read the PNG file data
> Convert PNG data to base64 data
> Send base64 data using websocket
> Receive base64 data
> Write the received data to the previously saved PNG file
> Load the PNG file as layer (pdb.gimp_file_load_layer)
> Delete PNG file
The closest solution that I have found is to use PIL/Pillow. I have tried installing PIL6.2.2 and earlier versions with GIMP's python but receive the error:
"The headers or library files could not be found for zlib, a required dependency when compiling Pillow from source."
If there is a solution within GIMP, or someone might be able to help me get Pillow to work, I would greatly appreciate it!
I am on Windows 10, using GIMP 2.10.38, and GIMP's Python 2.7.18. Please let me know if there is additional information I should provide.
Thank you for your time!
|
|
|
What have I forgotten? |
Posted by: sallyanne - 09-06-2024, 11:20 AM - Forum: General questions
- Replies (2)
|
 |
I am so used to doing gradients, but of late they are just not 'behaving like they should'
One a 'horizon to sky' I just tried and I got just the first color, Same happens with other gradients. Fixed color is white.
Could I have changed something in preferences. I restored tool presets on my gradient tool option dialog
Just tried another one and after a couple tries it turned to custom?
|
|
|
|