Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Script Fu - Batch Command Error
#1
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)))))
Reply


Messages In This Thread
Script Fu - Batch Command Error - by James Parkinson - 12-12-2022, 09:49 PM
RE: Script Fu - Batch Command Error - by Ofnuts - 12-12-2022, 10:11 PM
RE: Script Fu - Batch Command Error - by Kevin - 12-12-2022, 10:28 PM
RE: Script Fu - Batch Command Error - by Ofnuts - 12-14-2022, 06:11 PM

Forum Jump: