Post Reply 

Polygon selection in script

May 20, 2014, 02:17
Post: #1
Polygon selection in script
Hello all- I am writing a short script that calls python-fu-heal-selection. It works when I call the rectangle selection script, like:

Code:
(gimp-image-select-rectangle     image CHANNEL-OP-ADD     0 0 50 50)

However when I instead call..
Code:
(path-points (list->vector points)
(gimp-image-select-polygon     image CHANNEL-OP-ADD  point_count     path-points)
(variable point_count and points are both passed into the script)

I get the message:
"Heal selection-Warning: You must first select a region to heal."
So I must have a flaw in my call to gimp-image-select-polygon, right?

My batch file:
Code:
"C:\\Program Files\\GIMP 2\\bin\\gimp-console-2.8" --verbose -d -i -b "(myScript '(0 0 0 50 50 50 50 0 0 0) 5)"

(The polygon should be a self-connecting square)
If anyone could point out what I'm doing wrong, I'd appreciate it. (full script attached)


Attached File(s)
.txt  bad polygon select.txt (Size: 735 bytes / Downloads: 100)
Find all posts by this user
Quote this message in a reply
May 21, 2014, 00:30
Post: #2
RE: Polygon selection in script
Thanks very much! It was my point count that was off.
Find all posts by this user
Quote this message in a reply
Post Reply 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Run script on action rchav 2 102 Aug 13, 2018 14:57
Last Post: rchav
  Script Fu Errors Gimp 2.10.4 lightsaber jd3481 1 200 Aug 2, 2018 05:13
Last Post: paynekj
  Script-fu script to conversion pdf to image 4ever 12 5,989 Jul 17, 2018 16:01
Last Post: paynekj
  Problems with a bat script :( ThaUnknown_ 1 435 Mar 26, 2018 21:14
Last Post: paynekj
  Script-fu ordered file list vnicent 1 263 Mar 19, 2018 17:33
Last Post: paynekj

Forum Jump:


GIMP ForumPortalArchiveContactTermsRSS