Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Simplifying a path
#1
A new plugin. My try on simplifying paths. If Gimp already has a tool for that job, I hope somebody tells me.

The problem is hard, and all I can say is that mostly the plugin works all right though sometimes its decisions seem strange. Anyway, this is the first published version, and we can think the plugin to be still just experimental, so there is room for improvements. To get the plugin, go to

http://kmarkku.arkku.net/Path_modify_fil...aster.html

scroll to the bottom, and click the download button. You get a zip file. Unzip it and place the one file it contains (simplify_path.py) in your user's plug-ins folder. Then (re)start Gimp. To use the plugin: in the Paths tab, right-click the path you want to simplify and follow the links Tools > Modify path > Simplify.

The plugin takes a path and tries to diminish the number of anchors, doing some smoothing but hopefully not too much. An example: On the left you see a path and on the right its anchors:

   

With default input values the plugin did the following: Below, on the left you see the original path (blue) and the simplified version (red) on top of each other. It may be difficult to see from that picture but there are small differences: many small bends were smoothed out. On the right you see the anchors of the simplified path.

   

The GUI looks as follows:

   

I hope the meanings of the inputs are clear enough.

Of the inputs the last one (about selection) may be the most important in practice. It enables the user to restrict the effect to some subset of the anchors. I shall give examples in another post.

The plugin is based on a neat mathematical idea (I think), but unfortunately, when one starts to implement a neat idea, it usually happens that soon one is in the middle of a mess. The plugin is full of my own ad hoc solutions to various problems. Please report if you find it doing something too odd.
Reply


Messages In This Thread
Simplifying a path - by Ottia Tuota - 05-16-2021, 09:20 AM
RE: Simplifying a path - by Ottia Tuota - 05-16-2021, 10:47 AM
RE: Simplifying a path - by denzjos - 05-16-2021, 04:24 PM
RE: Simplifying a path - by Ottia Tuota - 05-16-2021, 05:06 PM
RE: Simplifying a path - by Krikor - 05-16-2021, 05:23 PM
RE: Simplifying a path - by Ottia Tuota - 05-16-2021, 07:10 PM
RE: Simplifying a path - by Ofnuts - 05-16-2021, 09:17 PM
RE: Simplifying a path - by Ottia Tuota - 05-17-2021, 04:52 AM
RE: Simplifying a path - by Ofnuts - 05-17-2021, 10:57 AM
RE: Simplifying a path - by Ottia Tuota - 05-18-2021, 03:18 PM
RE: Simplifying a path - by Ofnuts - 05-18-2021, 05:27 PM
RE: Simplifying a path - by Ottia Tuota - 05-19-2021, 07:46 AM
RE: Simplifying a path - by Ofnuts - 05-19-2021, 12:13 PM
RE: Simplifying a path - by Ottia Tuota - 05-19-2021, 02:33 PM
RE: Simplifying a path - by Ottia Tuota - 05-31-2021, 05:36 PM
RE: Simplifying a path - by Zero01 - 05-31-2021, 08:46 PM
RE: Simplifying a path - by Ottia Tuota - 06-01-2021, 06:16 AM
RE: Simplifying a path - by Ottia Tuota - 06-27-2021, 01:02 PM
RE: Simplifying a path - by Krikor - 11-16-2021, 05:06 PM
RE: Simplifying a path - by Ottia Tuota - 11-16-2021, 06:11 PM
RE: Simplifying a path - by mbelew - 05-17-2024, 02:46 PM
RE: Simplifying a path - by rich2005 - 05-17-2024, 03:17 PM
RE: Simplifying a path - by PixLab - 05-18-2024, 05:01 AM
RE: Simplifying a path - by Krikor - 05-18-2024, 05:10 PM
RE: Simplifying a path - by PixLab - 05-19-2024, 03:44 AM
RE: Simplifying a path - by gasMask - 05-19-2024, 11:43 PM
RE: Simplifying a path - by rich2005 - 05-20-2024, 07:11 AM
RE: Simplifying a path - by Ofnuts - 05-20-2024, 01:28 PM
RE: Simplifying a path - by Krikor - 05-20-2024, 06:36 PM
RE: Simplifying a path - by gasMask - 05-20-2024, 10:38 PM
RE: Simplifying a path - by rich2005 - 05-21-2024, 09:35 AM
RE: Simplifying a path - by Krikor - 05-21-2024, 03:15 PM
RE: Simplifying a path - by PixLab - 05-21-2024, 12:42 AM
RE: Simplifying a path - by denzjos - 05-21-2024, 05:36 PM
RE: Simplifying a path - by Krikor - 05-21-2024, 06:35 PM
RE: Simplifying a path - by denzjos - 05-22-2024, 06:51 AM
RE: Simplifying a path - by gasMask - 05-22-2024, 01:37 AM
RE: Simplifying a path - by Ottia Tuota - 07-04-2024, 03:26 PM
RE: Simplifying a path - by rich2005 - 07-04-2024, 03:38 PM

Forum Jump: