You are here

Curve Bend Between Paths

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0
Rate this item!
cbbp.jpg231.74 KB
curve-bend-between-paths.scm7.59 KB

This is a simplified front end to the curve bend script to help in straightening a distorted image. Create two paths with a maximum of 17 nodes each (drawn from left to right) tracing the existing image top and bottom curve, and it the script will calculate the curve bend parameters and run it to straighten the image.

After running the script, you can crop as desired, or perform further correction by shearing, or rotating the image by 90 degrees, drawing two new paths and running the script again

Image in sample was provided by lontarm at gimptalk.

EDIT: I have updated the script so it gets the curve a bit better. As some distortions are wonky, I have also added a slider to let you adjust the correction. The default is 0 (none), positive is more correction, -ve is less correction. This should let you dial in more problematic images without having to fudge the curves.

EDIT2: I have updated the script to include a quality option. This scales the image up vertically either 2 or 4 times before applying the curve bend, then scales it back down. This can greatly improve the quality of the curve bend results, with a proportional trade-off in speed.

-Rob A>

Code License: 
GIMP Version: 
Scripting Engine: 


Good job, Rob!

I tried to make it perform a flag wave just to see if it could, but the parameters wouldn't allow the entire effect to be seen. (I know that isn't what you created it for, but it was too tempting not to try)

Thanks for the script.

Subscribe to Comments for "Curve Bend Between Paths"