![]() |
Gimp Python script to do same thing as Free Select Tool - Printable Version +- Gimp-Forum.net (https://www.gimp-forum.net) +-- Forum: GIMP (https://www.gimp-forum.net/Forum-GIMP) +--- Forum: General questions (https://www.gimp-forum.net/Forum-General-questions) +--- Thread: Gimp Python script to do same thing as Free Select Tool (/Thread-Gimp-Python-script-to-do-same-thing-as-Free-Select-Tool) |
Gimp Python script to do same thing as Free Select Tool - sbhairava72 - 01-17-2018 I can use the 'Free Select Tool' to draw polygons.How do I use Gimp Python-fu to do the same thing? Should I use this?: pdb.gimp_edit_stroke_vectors(drawable, vectors) If so, I don't know what to do for the vectors parameter. I tried treating it like an array of coordinates, or an array of arrays of coordinates but that does not work. So far I have learned to create an image, open an image in a layer, copy a layer and more. I am not making good progress on polygons. RE: Gimp Python script to do same thing as Free Select Tool - Ofnuts - 01-17-2018 You are on the wrong track, pdb.gimp_edit_stroke_vectors(drawable, vectors) is the API to "Edit>Stroke Path". What you need is pdb.gimp_image_select_polygon(image, operation, num_segs, segs). |