所以我尝试运行本教程中的批处理代码:http://www.gimp.org/tutorials/Basic_Batch/
我将其复制并保存到.gimp-2.8脚本文件夹中
(define (batch-unsharp-mask 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-file-save RUN-NONINTERACTIVE
image drawable filename filename)
(gimp-image-delete image))
(set! filelist (cdr filelist)))))
Run Code Online (Sandbox Code Playgroud)
然后运行命令:
gimp-2.8 -i -b '(batch-unsharp-mask "*.png" 5.0 0.5 0)' -b '(gimp-quit 0)'
Run Code Online (Sandbox Code Playgroud)
但我得到了错误
Error: ( : 1) eval: unbound variable: *.png
Run Code Online (Sandbox Code Playgroud)
这似乎不是脚本的问题; 可能是我称呼它的方式或我错过了一些东西,但我无法弄明白.
我知道这已经是漫长的四个月了,但我只是在与我编写的 gimp (2.8) 脚本作斗争,并得到了一个重复的结果
batch command experienced an execution error:
Error: ( : 32578) eval: unbound variable: while
Run Code Online (Sandbox Code Playgroud)
事实证明,在我急于整合脚本目录时,我删除了对 /usr/share/gimp/2.0/scripts 的引用。显然该目录中有一些东西定义了“while”
编辑->首选项->文件夹->脚本
| 归档时间: |
|
| 查看次数: |
5830 次 |
| 最近记录: |