Carol suggested that removing the interactive flag from png-save might
help. If I do that, I get an error that directly says that a parameter
is missing from png-save, which is at least perfectly understandable.
The script, with Carol's suggestion commented out, is below.

Anyone else with an answer, or with a good way to see where bugs in
fu-scripts are in general?

thanks,
Dov


(define
  (dl-png2transindexed2 file)
  (let*
      (
       (img (car 
             (file-png-load 1 file file)
             )
            )
       (d (car (gimp-image-active-drawable img)))
       )
    (gimp-layer-add-alpha (car (gimp-image-get-active-layer img)))
    (gimp-by-color-select d '(255 255 255) 0 2 0 0 0 0)
    (gimp-edit-clear)
    (gimp-convert-indexed img 0 0 255 0 0 "")
    (file-png-save 1 img d file file 0 6 0 0 0 1 1)
;    (file-png-save img d file file 0 6 0 0 0 1 1)
    )
)
 
(script-fu-register "dl-png2transindexed2"
"<Toolbox>/Xtns/Script-Fu/png2transindexed2"
"png2indexed2"
"Dov Kruger& Elena Zagrai"
"(c) 2004 Stevens Institute of Technology"
"2004-02-25"
""
SF-FILENAME "File" "file.png"
)


_______________________________________________
Gimp-developer mailing list
[EMAIL PROTECTED]
http://lists.xcf.berkeley.edu/mailman/listinfo/gimp-developer

Reply via email to