Hello, I use SF-WHATEVER, I just had a typo in the email. The complete script is my previous email and also attached to this email.
I test by copying the script into /home/en/.gimp-2.2/scripts, and then do a refresh from gimp/Xtns menu. A reference script copied from /usr/share/gimp/2.0/scripts works perfectly; however not a single scm script does file operations. I suspect, that file operations simply do not work with scm. That what the tutorial implicates. -eleonora > > > With SF_STRING or SF_FILENAME the error remains the same. > > Error: unbound variable (errobj /tmp/x.gif) > > Use SF-STRING or SF-FILENAME, not SF_STRING, SF_FILENAME. > > If that does not fix your problem then post your script; it is > difficult to find bugs when only fragments of code are provided. > > _______________________________________________ > Gimp-user mailing list > Gimp-user@lists.XCF.Berkeley.EDU > https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-user -- GMX Kostenlose Spiele: Einfach online spielen und Spaß haben mit Pastry Passion! http://games.entertainment.gmx.net/de/entertainment/games/free/puzzle/6169196
; The GIMP -- an image manipulation program ; Copyright (C) 1995 Spencer Kimball and Peter Mattis ; ; Glogo Simple --- save as simple as possible an image as Linux Boot Logo ; Based on Jens Ch. Restmeiers' glogo plug-in ; Copyright (C) 1998 Clifford Wolf ; [EMAIL PROTECTED] ; ; This program is free software; you can redistribute it and/or modify ; it under the terms of the GNU General Public License as published by ; the Free Software Foundation; either version 2 of the License, or ; (at your option) any later version. ; ; This program is distributed in the hope that it will be useful, ; but WITHOUT ANY WARRANTY; without even the implied warranty of ; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ; GNU General Public License for more details. ; ; You should have received a copy of the GNU General Public License ; along with this program; if not, write to the Free Software ; Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. (define (script-fu-glogo-simple2 srcimg dummy filename) (let* ( (img2 (car (gimp-channel-ops-duplicate srcimg))) (img16 (car (gimp-channel-ops-duplicate srcimg))) (img224 (car (gimp-channel-ops-duplicate srcimg))) (drawa (car (gimp-image-active-drawable srcimg))) (drcol (car (gimp-drawable-color drawa))) ) ; ; Set names to the images (debug-info) ; (gimp-image-set-filename img2 "glogo-bw") (gimp-image-set-filename img16 "glogo-16") (gimp-image-set-filename img224 "glogo-224") ; ; Resize (i.e. scale) them all ; (gimp-image-scale img2 80 80) (gimp-image-scale img16 80 80) (gimp-image-scale img224 80 80) ; ; Convert them to RGB if they are not ; (if (= drcol 0) (begin (gimp-convert-rgb img2) (gimp-convert-rgb img16) (gimp-convert-rgb img224) ) ) ; ; Flatten it ; (gimp-image-flatten img2) (gimp-image-flatten img16) (gimp-image-flatten img224) ; ; Now change the palletes ; (gimp-convert-indexed-palette img2 1 3 0 "") (gimp-convert-indexed-palette img16 1 0 16 "") (gimp-convert-indexed-palette img224 1 0 224 "") ; ; Save it as gifs (not needed anymore) ; ; (file-gif-save 1 img2 (car (gimp-image-active-drawable img2)) ; "/tmp/x-2.gif" "/tmp/x-2.gif" 0 0 0 0) ; (file-gif-save 1 img16 (car (gimp-image-active-drawable img16)) ; "/tmp/x-16.gif" "/tmp/x-16.gif" 0 0 0 0) ; (file-gif-save 1 img224 (car (gimp-image-active-drawable img224)) ; "/tmp/x-224.gif" "/tmp/x-224.gif" 0 0 0 0) ; ; Save it as linux boot logo ; ; (gimp-message (string-append "Debug-Info: img2=" (number->string img2 10) ; " img16=" (number->string img16 10) ; " img224=" (number->string img224 10))) (extension-linux-logo 1 filename (car (gimp-image-active-drawable img2)) (car (gimp-image-active-drawable img16)) (car (gimp-image-active-drawable img224)) ) ; ; Free the images ; (gimp-image-delete img2) (gimp-image-delete img16) (gimp-image-delete img224) ) ) (script-fu-register "script-fu-glogo-simple2" "<Image>/Script-Fu/Save as Linux Boot Logo2" "Saves any given image as Linux Boot Logo2" "Clifford Wolf" "Clifford Wolf" "Aug 1998" "" SF-IMAGE "Image to Glogo Simple" 0 SF-DRAWABLE "Drawable to Glogo Simple" 0 SF-VALUE "File Name" "/tmp/x.gif" )
_______________________________________________ Gimp-user mailing list Gimp-user@lists.XCF.Berkeley.EDU https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-user