12-12-2022, 09:49 PM
Learning Scrpt Fu is slow. Any assistance is welcome regarding the Error message.
I am trying to replicated the reported success of others who have posted online. I am running GIMP 2.10.32.
Opening CMD Window within the folder:
C:\Users\parkinsj\Desktop\GIMP_Batch\
; which contains two JPG files, I ran the following:
gimp-2.10 -i -b "(batch-auto-fix "C:\Users\parkinsj\Desktop\GIMP_Batch\img*.jpg")" -b "(gimp-quit 0)"
The result was:
batch command experienced an execution error:
Error: eval: unbounded variable: C:\Users\parkinsj\Desktop\GIMP_Batch\img*.jpg
The SCM file batch-auto-fix.scm is at location:
C:\Program Files\GIMP 2\share\gimp\2.0\scripts
The SCM file reads:
(define (batch-auto-fix pattern
radius
amount
threshold)
(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))))
(plug-in-unsharp-mask RUN-NONINTERACTIVE
image drawable radius amount threshold)
(gimp-levels-stretch drawable)
(plug-in-color-enhance RUN-NONINTERACTIVE
image drawable)
(gimp-file-save RUN-NONINTERACTIVE
image drawable filename filename)
(gimp-image-delete image))
(set! filelist (cdr filelist)))))
I am trying to replicated the reported success of others who have posted online. I am running GIMP 2.10.32.
Opening CMD Window within the folder:
C:\Users\parkinsj\Desktop\GIMP_Batch\
; which contains two JPG files, I ran the following:
gimp-2.10 -i -b "(batch-auto-fix "C:\Users\parkinsj\Desktop\GIMP_Batch\img*.jpg")" -b "(gimp-quit 0)"
The result was:
batch command experienced an execution error:
Error: eval: unbounded variable: C:\Users\parkinsj\Desktop\GIMP_Batch\img*.jpg
The SCM file batch-auto-fix.scm is at location:
C:\Program Files\GIMP 2\share\gimp\2.0\scripts
The SCM file reads:
(define (batch-auto-fix pattern
radius
amount
threshold)
(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))))
(plug-in-unsharp-mask RUN-NONINTERACTIVE
image drawable radius amount threshold)
(gimp-levels-stretch drawable)
(plug-in-color-enhance RUN-NONINTERACTIVE
image drawable)
(gimp-file-save RUN-NONINTERACTIVE
image drawable filename filename)
(gimp-image-delete image))
(set! filelist (cdr filelist)))))