Here are two extensions for Inkscape:

Installation:

Pattern along path is now part of Inkscape (0.46).

Scatter arrived too late for 0.46... You'll have to add it by hand.
Copy the following files to the "Extensions" folder of inkscape (0.46 needed):

  1. pathscatter.py
  2. pathscatter.inx
  3. simpletransform.py
(bugfix: simpletransform.py is slightly modified from the 0.46 release to support rects) (here is also a derivation of the "interpolate" effect, handling groups, clones, etc..., and respecting z-Order)

Below is my somewhat outdated presentation page of pattern along path effect: I guess all this information can be found in the inkscape manual now...


Pattern along path presentation:

For instance, you can draw a straight snake, or piece of rope, and then use this extension to give it its final wavy shape. It is pretty much like you had defined a new "stroke pattern".

a deformed inkscape logo

a fish

a... thing (?)

Usage:

  1. Select the (group of) path(s) you want to deform (call it the pattern). [bring it to front]
  2. Select some more (group of) path(s) (Maj-Click): they will control the deformation (call them "skeletons")
  3. Choose the menu Effect>Modify Path>Path Deform and fill in the different options!

Notice: Due to a minor bug in the interaction of scripts with inkscape, the object interpreted as the pattern is the top most object in the z-order. This is not very handy, and will be modified when possible.

To obtain better results, here is an insight about what is going on: consider the horizontal going through the middle of the bounding box of the pattern, and its "normal bundle": the collection of all the vertical lines meeting it. Think of this as the initial state of the plane. In particular, think of the pattern as painted on these vertical lines.
Now move and bend the horizontal line to make it fit a "skeleton", and see what happens to the normals: they move and rotate, and might even cross... If your pattern was painted on them, it would end in a new, eventually very distorted position: this is what this extension is supposed to do.
Notice that you might have to subdivide the pattern paths in in the distorted regions to obtain more accurate results.

The extension comes with several more or less self explanatory options...

tangential and normal offset

 

some examples withe different options

Here is an SVG file containing the examples shown on this page.

Comments/Contact:

You can contact me at:  myname@gmail.com where myname should be replaced by jf.barraud.

Of course, this extension can be emproved in many ways:

  • It should work on any kind of shape (not only paths) (DONE!)
  • It would be nice to have it compatible with the greeeeat new features of 0.45 like mesh gradient fill and so.
  • It could also automatically subdivide the paths where needed, to deform them more accurately.
  • But the best thing would be to have it coded right in inkscape and see every thing update dynamically!...

History:

2006-11-21:
Splitted the code into two pieces and changed the name:
  • 'pathmodifier.py': a general class for path deforming effects. It provides methods to easily handle groups, clones, object to path conversion...
  • 'pathalongpath.py': a subclass actually responsible for the deformation
Added support of Clones
Added support of Rect, Ellipses, Stars... are now supported.
2006-11-13:
Changed the UI a bit: "pattern" is the first selected object while all the other are skeletons now.
2006-11-12:
Accept groups for both "pattern" and "control path".
Duplicate the pattern before deformation.
2006-11-10:
Shapes are moved onto the deformer by default. Added tangential and normal offsets.
These parameters were determined by relative position of objects before, but it turned out not to be very intuitive... With this new behaviour, it works a bit like applying a generalized stroke style.
2006-11-09:
Hello world!