FRIHOST FORUMS SEARCH FAQ TOS BLOGS COMPETITIONS
You are invited to Log in or Register a free Frihost Account!


gimp - resize your pics with shell





ralcantara
Hi people

here there is another script to make easy the task of resize pictures in gimp.

1 ) Put this script below in /home/ralcantara/.gimp-2.6/scripts/resize.scm
(define (simple-unsharp-mask filename
radius
amount
threshold)
(let* ((image (car (gimp-file-load RUN-NONINTERACTIVE filename filename)))
(drawable (car (gimp-image-get-active-layer image))))
(plug-in-unsharp-mask RUN-NONINTERACTIVE
image drawable radius amount threshold)
(gimp-file-save RUN-NONINTERACTIVE image drawable filename filename)
(gimp-image-delete image)))


2) Create the shell script gimp.resize.sh
#!/bin/bash

gimp -i -b '(simple-unsharp-mask "'$1'" 5 0 5)' -b '(gimp-quit 0)'


3) Set exec permission
$ chmod +x script gimp.resize.sh


4) Finally resize your pic.
$ ./gimp.resize.sh <your_pic>.jpg


best regards
Related topics
FTP program
funny pics 1
some funny pics 1
What do you use to make your page layout?
South Brazil Beach... very nice! | 640x480 images
more pics
Dose Anybody Know Where to find Photoshop pro Free Software.
GIMP?
Good photo editing software?
Image resize function
Just an ad button made with photoshop and gimp
My hiking/survival gear, explained. (Warning, ~90 pics)
Pics from a building site
My Olympic National Park Trip (Warning: 32MB of pics!)
Reply to topic    Frihost Forum Index -> Computers -> Software

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2011 Frihost, forums powered by phpBB.