Hi,

I'm trying to use the batch mode to process a large set of TIFF files. I've modified the script at:

http://www.gimp.org/tutorials/Basic_Batch/

to convert the images from RGB to indexed (modified script below). However, when I try and run it nothing happens. I included the GIMP install in my path (running on Windows XP) and used the command:

gimp-2.2.exe -i -b '(convert-rgb-indexed "*.tif")' '(gimp-quit 0)'

The processor spikes momentarily and the process (gimp-2.2.exe) shows up in the list of processes, but nothing actually happens. I'm not getting any error messages, and the files are not being changed.

Any suggestions?

Thanks,

Greg


Code:

  (define (convert-rgb-indexed pattern)
  (let* ((filelist (cadr (file-glob pattern 1))))
    (while filelist
           (let* ((filename (car filelist))
                  (image (car (gimp-file-load RUN-NONINTERACTIVE
                                              filename filename)))
                  (drawable (car (gimp-image-get-active-layer image))))
             (gimp-image-convert-indexed RUN-NONINTERACTIVE
                                   image 0 0 255 0 0 "")
             (set! drawable (car (gimp-image-get-active-layer image)))
             (gimp-file-save RUN-NONINTERACTIVE
                             image drawable filename filename)
             (gimp-image-delete image))
           (set! filelist (cdr filelist)))))



--
--------------------------------------------------------------------
Gregory Yetman
Center for International Earth Science Information Network (CIESIN)
Columbia University
URL: http://www.ciesin.columbia.edu/
e-mail: gyetman (at) ciesin.columbia.edu
tel: (845) 365-8982
--------------------------------------------------------------------

_______________________________________________
Gimp-user mailing list
Gimp-user@lists.XCF.Berkeley.EDU
https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-user

Reply via email to