Welcome, Guest |
You have to register before you can post on our site.
|
Forum Statistics |
» Members: 5,493
» Latest member: Игорь
» Forum threads: 7,123
» Forum posts: 38,951
Full Statistics
|
|
|
gimp.image_list() vs pdb.gimp_image_list() |
Posted by: DebianFanatic - 10-07-2018, 09:57 PM - Forum: Scripting questions
- Replies (7)
|
|
➤> pdb.gimp_image_list()
(1, (1,))
➤> gimp.image_list()
[<gimp.Image '[KentsHouse-FamInDen] (imported)'>]
Obviously two different commands (procedures? attributes? properties?), despite their similar names.
The Python Console "Browse" button shows info about pdb.gimp_image_list(), but seems to know nothing about the other. Where is this other command coming from (if not GIMP's internal Procedure DataBase), and how would I know about it if I hadn't just stumbled onto it?
--
Kent
|
|
|
Is there a function or filter |
Posted by: trandoductin - 10-07-2018, 02:40 PM - Forum: General questions
- Replies (2)
|
|
That will help me pixelize an image with varying sizes dependent on similar colors.
Like pixelize just does constant size.
I want it to get varying possible pixelize dependent on similar colors for example if the area of similar colors is larger it'll return the larger size that i can pixelize on and if an area of similar colors is smaller it'll return the smaller size that i can pixelize on?
I hope I explained that right.
|
|
|
Python-Fu - pdb.query ; how to filter to readable output |
Posted by: DebianFanatic - 10-06-2018, 11:23 PM - Forum: Scripting questions
- Replies (5)
|
|
Caveat: I'm new to Python & Object-Oriented Programming (and not particularly skilled with GIMP)
I'm trying to learn a little about automating GIMP, and found this tutorial:
https://www.gimp.org/tutorials/Automate_Editing_in_GIMP
I was able to do the first little example, finding the python console within GIMP, and learned quite a bit, enough to do some experimenting on my own.
One thing I wanted to experiment with was setting the grid color, and I guessed at several properties ("attributes"?) of the object (?) "pdb" (which I googled to discover was GIMP's "procedural database", which I take to mean the database of scriptable procedures within GIMP), but none of my attempts (like "pdb.gimp_image_grid_set_fgcolor()" or pdb.gimp_image_grid_set_foreground_color()", etc) worked. So I figured there must be a way to list all the attributes ("properties"?) of an object, and after quite a bit of googling, came up with two [relatively easy, one-liner) possibilities:
dir(pdb)
and
pdb.query()
(I see they produce different info, so I'm unclear as to which, if either, will be my better option, but that's a question for later).
The problem is that both commands give too much information to look through efficiently.
So I did yet more googling, and came up with:
re.findall("grid",str(pdb.query()))
hoping to just get the items mentioning "grid", but all that returned was a bunch of "grid"s.
In bash, I'd try something like "pdb.query() | grep grid" (which might or might not give me usable results).
So, my questions:
1. Which is better and why, pdb.query() or dir(pdb), or are neither of these suitable for learning about the attributes/properties of an object?
2. Is there a better way of learning about the properties/attributes of an object (to figure out what attribute/property to tinker with to change the color of the grid a la the tutorial mentioned above?
3. How do I list all the attributes/properties of an object that has a lot of these attributes/properties and filter the results or present them in a way that is digestible, particularly as it relates to the output of "pdb.query" or "dir(pdb)"?
Thanks!
--
Kent
|
|
|
macros vs script-fu vs python-fu |
Posted by: DebianFanatic - 10-06-2018, 08:22 PM - Forum: Scripting questions
- Replies (5)
|
|
Absolute Beginner here, to python & to scripting/macroing/extending GIMP.
I had a vague remembrance that GIMP is "scriptable", and the term "macro" came to my mind.
After considerable googling, I've about decided that "macro" is an inaccurate term, and "extending GIMP" is the correct terminology (although I tend to think of "extending" as adding new features more then simply automating the features that already exist).
I've also about decided that "script-fu" and "python-fu" are "the" automating options; I'm unsure if either is built-in, but I didn't notice these options in my Gimp's "Filter" menu until I did, on my Debian box, "aptitude install gimp-python". Not saying they weren't there; I just didn't know to look for them until after I added gimp-python to my computer.
So my first question (with more to come under different posts): Am I getting close to understanding the terminology/concepts for automating steps in GIMP? To give you an idea of where I'm trying to head, I just added a bunch of numbered labels to 28 people in a photo:
I did this manually by creating 28 layer groups, one for each label, and then on one layer drawing an ellipse and bucket-filling it, and then creating a text layer centered on the white ellipse. Afterward I realized that this repetitive process could probably be automated. My next questions will tackle various aspects of this task, but first I just want to make sure I'm understanding the concepts/terminology.
Thanks!
--
Kent
|
|
|
One heightmap out of many gimp 2.8 |
Posted by: JKLopez - 10-06-2018, 04:36 PM - Forum: General questions
- Replies (6)
|
|
Hi everyone, I need help figuring out how to make a single hight map out of 6 height maps I have, there in .png format I downloaded them from terrain.party, I’d just download as one but the area is to big, so I was wondering if anyone knew how to make them into one map, it’s for unity 4, thanks for any help ...
|
|
|
In a whirl |
Posted by: QuinB - 10-05-2018, 07:22 PM - Forum: General questions
- Replies (2)
|
|
Now, I do understand that trying to duplicate the results of an older version of software on the latest'n'greatest can be troublesome, but I was looking over a v2.6 tutorial Cool wave effect and came unstuck.
The tutorial uses the solid noise function as a basis, claims to throw in difference clouds, lightens things up with colour level adjustment and throws in a motion blur before applying the whirl and pinch function. Then is duplicates the work layer and applies Lighten Only mode to the top layer.
At that point, the reality diverges from the tutorial, as no change is seen with the Lighten Only mode addition (no idea HOW Lighten Only is meant to have any effect with two images with exactly the same values on each pixel). Having tried default Lighten Only mode as well as Legacy(well you never know), and then run through every other mode available (well you never know), I'm stuck as to the solution - other than v2.6 was A Long Time Ago and we do things differently now.
So. Can anybody suggest how the effect shown in the tutorial is produced?
(apart from the tutor fudging the results, of course. I mean; who'd DO a thing like that?)
|
|
|
|