michael@[EMAIL PROTECTED]
cat scanguides.scm
; uses guillotine on 4 scanned normal size photos to slice them out into
; 4 new images and save them
;
; use scanguides *.png 0 1 50 50
; filename guide directions and percents
; gimp -i -b '(scanguides "*.png" 0 1 50 50)' -b '(gimp-quit 0)'
(define (scanguides filename direction1 direction2 percent1 percent2)
(let* ((filelist (cadr (file-glob pattern 1))))
(while (not (null? filelist))
(let* ((filename (car filelist))
(image (car (gimp-file-load RUN-NONINTERACTIVE
filename filename)))
(drawable (car (gimp-image-get-active-layer
image))))
(script-fu-guide-new-percent 0 image drawable direction1
percent1)
(script-fu-guide-new-percent 0 image drawable direction2
percent2)
(plug-in-guillotine 0 image drawable)
(gimp-file-save RUN-NONINTERACTIVE image drawable filename
filename)
(gimp-image-delete image)))
(set! filelist (cdr filelist))))
any idea what is wrong with this script?
it should save 4 slices in 4 different files after run.
i just get an "unexpected error" message when running with the above
command.