I have the following script saved in ~/.gimp2.6/scripts/crop-
pandacam.scm:
// === file starts on next line ===
(
define ( crop-pandacam filename )
(
let* ( ( image ( car ( gimp-file-load RUN-NONINTERACTIVE filename
filename ) ) )
( drawable ( car ( gimp-image-get-active-layer image ) ) )
)
( gimp-image-crop RUN-NONINTERACTIVE image 322 242 52 357 )
( gimp-file-save RUN-NONINTERACTIVE image drawable filename
filename )
( gimp-image-delete image )
)
)
// === file ends on previous line ===
which I want to use to crop files in batch mode, but when I run it I
get the following:
denis@denis-desktop:~/Pictures$ gimp --verbose -i -b '(crop-pandacam
"Screenshot.png")' -b '(gimp-quit 0)'
INIT: gimp_load_config
Parsing '/home/denis/.gimp-2.6/unitrc'
Parsing '/etc/gimp/2.0/gimprc'
Parsing '/home/denis/.gimp-2.6/gimprc'
gimp_composite: use=yes, verbose=no
Processor instruction sets: +mmx +sse +sse2 -3dnow -altivec -vis
INIT: gimp_initialize
INIT: gimp_real_initialize
INIT: gimp_restore
Parsing '/home/denis/.gimp-2.6/parasiterc'
Loading 'brush factory' data
Loading 'pattern factory' data
Loading 'palette factory' data
Loading 'gradient factory' data
Loading fonts
Parsing '/home/denis/.gimp-2.6/templaterc'
INIT: gimp_real_restore
Parsing '/home/denis/.gimp-2.6/pluginrc'
Starting extension: 'extension-script-fu'
No batch interpreter specified, using the default 'plug-in-script-fu-
eval'.
batch command experienced an execution error
EXIT: gimp_exit
EXIT: gimp_real_exit
Terminating plug-in: '/usr/lib/gimp/2.0/plug-ins/script-fu'
Terminating plug-in: '/usr/lib/gimp/2.0/plug-ins/script-fu'
Writing '/home/denis/.gimp-2.6/templaterc'
Writing '/home/denis/.gimp-2.6/parasiterc'
Writing '/home/denis/.gimp-2.6/unitrc'
EXIT: batch_exit_after_callback
The error message is less than helpful :(
Can anyone see what's wrong with the script?
Denis McMahon