Splitting an image into many randoms pieces

I have an image of a map of a certain region, and I want to show the map divided to about 1000 small pieces. This should be a metaphor of dividing the region to many small land-plots.

I need two types of division:

  • A vertical division – all division lines are vertical but with randomly varying intervals.
  • An arbitrary division – irregular division lines, that should give the impression of an anarchic (not planned) division of the land.

I looked for smashing effects in gimp, but found effects of broken glass, which does not fit in this context (it is not glass that is broken here, it is land).

I also found some tutorials that require me to draw the smashing lines myself, which is a lot of work since there are many pieces here. I am looking for an automatic way to create random, irregular division lines.



I use scriptographer and (more recently) paper.js for creating these sorts of generative graphics. You can create vector graphics in the browser, then export to SVG for more manipulation in Illustrator, Inkscape, or your program of choice.

Here’s a script modified from an old version of scriptographer for paper.js:


To use, click and drag in the Results pane to create a network of random lines. Press Shift+Enter to save the results to an .SVG file.

You can modify the number of lines generated and the speed of growth by the max and size values at the top of the Javascript pane.

Source : Link , Question Author : Erel Segal-Halevi , Answer Author : Alex Blackwood

Leave a Comment