| Welcome, Guest |
You have to register before you can post on our site.
|
|
|
| Problem posting an update to my plugin |
|
Posted by: Scallact - Yesterday, 05:46 PM - Forum: Gimp-Forum.net
- No Replies
|
 |
I tried to post a new thread for my updated pl_stroke_arrows plugin, and was granted the "Your are in violation with the forum's rules" message, with a link to said rules.
I don't get what part of my message did upset the forum filter, my post was similar to the previous update.
Any idea what could be wrong?
|
|
|
| Setting a default directory to save files |
|
Posted by: Ofnuts - Yesterday, 05:30 PM - Forum: Tutorials and tips
- No Replies
|
 |
You will have noticed that Gimp is hell-bent into saving everything by default in your Documents folder. It's no completely Gimp faults, it is the behavior of the GTK file dialog thayt Gimp uses.
The simple but incomplete solution is to add your favorite folder(s) to the Bookmarks panel on the left.
But you can also make Gimp use any directory by making it think it is your Documents folder.
- The FreeDesktop standard defines several directories: DESKTOP, DOWNLOAD, TEMPLATES, PUBLICSHARE, DOCUMENTS, MUSIC, PICTURES, VIDEOS
- A configuration file called user-dirs.dirs can be used to define what actual directory is used for these symbolic directories. This is typically used to give language-dependent names.
- user-dirs.dirs is normally in ~/.config but you can tell the desktop code to use a different one by setting XDG_CONFIG_HOME environment variable to a directory that contains another version of user-dirs.dirs
- You update the file with the xdg-user-dirs-update command, and you can check it use the xdg-user-dir command. These two commands will of course check the XDG_CONFIG_HOME environment variable.
So, all that is needed is to prepare a user-dirs.dirs pointing to the required directory, and set the XDG_CONFIG_HOME environment variable to point to the alternate user-dirs.dirs directory in a script before calling Gimp.
So for instance, setting your destination directory to ~/tmp:
Do once:
Code:
export XDG_CONFIG_HOME=~/tmp/ # directory for user-dirs file, and your Gimp files
xdg-user-dirs-update --set DOCUMENTS ~/tmp # Creates/updates the user-dirs file
Before calling Gimp (so create/modify script):
Code:
export XDG_CONFIG_HOME=~/tmp/ # tell FreeDesktop where to look for directories definition
gimp # start Gimp (can also be "exec gimp" to get rid of one level of shell)
The exemple above keeps the user-dirs.dir file and the Gimp files in the same directory but using different directories is left as an exercise for the reader.
If any Windows or OSX users are reading this, I wonder if this applies in other OS as well. If you are missing the xdg-user-dirs-update command, user-dirs.dirs is a plain text file and it looks like this:
# This file is written by xdg-user-dirs-update
# If you want to change or add directories, just edit the line you're
# interested in. All local changes will be retained on the next run.
# Format is XDG_xxx_DIR="$HOME/yyy", where yyy is a shell-escaped
# homedir-relative path, or XDG_xxx_DIR="/yyy", where /yyy is an
# absolute path. No other format is supported.
#
XDG_DOCUMENTS_DIR="$HOME/tmp"
|
|
|
| Fix low resolution images |
|
Posted by: JoeCool59 - 12-05-2025, 06:33 PM - Forum: General questions
- Replies (5)
|
 |
I'm a casual GIMP user. I have some old digital images shot or digitized in low resolution (pixelated). The one I'm currently working on was a jpeg from around 1990. I opened it and screenshot it and now it's a 600ppi png, but the image retains all the compression artifacts that are left over from its original life as a 70ppi jpeg. Is depixelating it an art? I recognize that GIMP is incapable of knowing what information should be in the image. I'm eager to learn new things in GIMP.
|
|
|
| GIMP 3 script-fu not loading and run with error when Loaded through Console |
|
Posted by: markhahn2000 - 12-04-2025, 09:06 PM - Forum: Scripting questions
- Replies (1)
|
 |
new to v3 and having scripting issues.
My test case is a published "hello World"script. (https://testing.developer.gimp.org/resou...script-fu/)
On MacOS I have given GIMP full access in system settings. I have placed this .scm in a subdirectory with the same name as the executable .scm file. In Folders, this script directory is the first listed.
It does not show up when I restart GIMP.
I've read that I can load it in the Console, and when I do this, I get the error:
"Error: eval: unbound variable: (/Users/mark/GIMP_scriptfu/mh_hello_world3/mh_hello_world.scm : 35) [] "
On line 35 in the script, it holds the copyright year. How is this causing this script to error out?
I have tried different example scripts and am getting similar errors.
I am new to this. Thanks for any help!
Code:
#!/usr/bin/env gimp-script-fu-interpreter-3.0
(define (script-fu-zemarmot-hello-world
image
drawables
font
compute-size
size
text)
(script-fu-use-v3)
(let* ((layer (gimp-text-layer-new image text font size UNIT-PIXEL)))
(gimp-image-undo-group-start image)
(gimp-image-insert-layer image layer -1 0)
(if (= compute-size TRUE)
(let* ((image-width (gimp-image-get-width image))
(layer-width (gimp-drawable-get-width layer)))
(begin
(set! size (* size (/ image-width layer-width)))
(gimp-text-layer-set-font-size layer size UNIT-PIXEL)
)
)
)
(gimp-image-undo-group-end image)
)
)
(script-fu-register-filter "script-fu-zemarmot-hello-world"
"Script-Fu v3 Hello World"
"Official Hello World Tutorial in Script-Fu v3"
"Jehan"
"Jehan, Zemarmot project"
"2025"
"*"
SF-ONE-OR-MORE-DRAWABLE
SF-FONT "Font" "Sans-serif"
SF-TOGGLE "Compute Ideal Size" #f
SF-ADJUSTMENT "Font size (pixels)" '(20 1 1000 1 10 0 1)
SF-STRING "Text" "Hello World!"
)
(script-fu-menu-register "script-fu-zemarmot-hello-world" "<Image>/Hello W_orlds")
|
|
|
| Déformation par "Cage" |
|
Posted by: Bart Simpson - 12-02-2025, 05:06 PM - Forum: General questions
- Replies (7)
|
 |
Bonjour,
je souhaite poser une question sur l'outil de déformation par cage.
Mais avant d'aller plus loin et de poser ma question, je doit préciser que je suis français et que je ne parle pas anglais.
Aussi j'utilise le fonction de traduction automatique.
Et avant d'entamer la discussion je souhaite vérifier que le traducteur fonctionne et que vous recevez bien mon message en anglais.
La communication français/anglais est elle correcte?
Bien à vous,
Bart
|
|
|
| Plugins with Gimp 3.2 RC1 ? |
|
Posted by: Xxxx - 12-02-2025, 03:53 PM - Forum: General questions
- Replies (1)
|
 |
I installed Gimp 3.06 (package from my distro) and 3.2 RC1 self-compiled.
My plugins (e.g. Gmic, Batcher, Resynthetizer) copied to the appropriate directories only work with 3.06...
|
|
|
| Average colour in GIMP - one click |
|
Posted by: chuckhenrich - 12-01-2025, 11:02 AM - Forum: Extending the GIMP
- Replies (8)
|
 |
I’ve published a new plugin that generates the average colour for any RGB or greyscale image. It sits at the end of the Colors menu: “Average colour” (after you install it properly of course).
I was surprised that average colour wasn’t a thing in GIMP. I did a lot of research and discovered the topic generated various solutions that were all challenging in one way or another.
Then I found a thread from 2014 where someone suggested a really simple manual approach. So I took that as inspiration and automated it.
You can read more about it and download it here:
https://www.chuckhenrich.com/average-col...mp-plugin/
Also, I wrote a follow-up blog post on the wider topic of the importance of using industry standards in GIMP, with average colour as an example:
https://www.chuckhenrich.com/average-col...-standard/
The plug-in is 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) (繁體中文)
Feedback and suggestions welcome and encouraged!
|
|
|
|