RSS/Atom feed Twitter
Site is read-only, email is disabled

script-fu-save-anim-layers

This discussion is connected to the gimp-user-list.gnome.org mailing list which is provided by the GIMP developers and not related to gimpusers.com.

This is a read-only list on gimpusers.com so this discussion thread is read-only, too.

7 of 8 messages available
Toggle history

Please log in to manage your subscriptions.

script-fu-save-anim-layers Alec Burgess 19 Oct 00:19
  script-fu-save-anim-layers Sven Neumann 19 Oct 00:45
   script-fu-save-anim-layers Alec Burgess 19 Oct 03:46
    script-fu-save-anim-layers Sven Neumann 19 Oct 13:14
    script-fu-save-anim-layers Kevin Cozens 19 Oct 22:02
  script-fu-save-anim-layers saulgoode@flashingtwelve.brickfilms.com 19 Oct 03:12
48FBAF13.9040905@gmail.com 07 Oct 20:19
  script-fu-save-anim-layers Alec Burgess 20 Oct 00:06
Alec Burgess
2008-10-19 00:19:55 UTC (over 16 years ago)

script-fu-save-anim-layers

Script:
http://flashingtwelve.brickfilms.com/GIMP/Scripts/save-anim-layers.scm (apparently by Saul Goode 3/11/2008)

This script was mentioned in bugzilla: Bug 556548 – Layer extraction script http://bugzilla.gnome.org/show_bug.cgi?id=556548

Attempts to execute it result in:

Error while executing script-fu-save-anim-layers: Error: Bad syntax of binding spec in let* : ((image) (buffer))

I think this is due to changes in script-fu (?) but don't know enough about script-fu to correct it. Could someone help?

Also ... in the script comments, its not clear which directory/folder the files will be created?

Sven Neumann
2008-10-19 00:45:48 UTC (over 16 years ago)

script-fu-save-anim-layers

Hi,

On Sat, 2008-10-18 at 18:19 -0400, Alec Burgess wrote:

Error while executing script-fu-save-anim-layers: Error: Bad syntax of binding spec in let* : ((image) (buffer))

I think this is due to changes in script-fu (?) but don't know enough about script-fu to correct it. Could someone help?

This is explained in the release notes for GIMP 2.6: http://gimp.org/release-notes/gimp-2.6.html

Sven

saulgoode@flashingtwelve.brickfilms.com
2008-10-19 03:12:51 UTC (over 16 years ago)

script-fu-save-anim-layers

Script has been updated.

Quoting Alec Burgess :

Script:
http://flashingtwelve.brickfilms.com/GIMP/Scripts/save-anim-layers.scm (apparently by Saul Goode 3/11/2008)

This script was mentioned in bugzilla: Bug 556548 – Layer extraction script http://bugzilla.gnome.org/show_bug.cgi?id=556548

Attempts to execute it result in:

Error while executing script-fu-save-anim-layers: Error: Bad syntax of binding spec in let* : ((image) (buffer))

I think this is due to changes in script-fu (?) but don't know enough about script-fu to correct it. Could someone help?

Also ... in the script comments, its not clear which directory/folder the files will be created?

--
Regards ... Alec (buralex@gmail & WinLiveMess - alec.m.burgess@skype)

Alec Burgess
2008-10-19 03:46:26 UTC (over 16 years ago)

script-fu-save-anim-layers

Sven Neumann (sven@gimp.org) wrote (in part) (on 2008-10-18 at 18:45):

On Sat, 2008-10-18 at 18:19 -0400, Alec Burgess wrote:

> > Error while executing script-fu-save-anim-layers: > > Error: Bad syntax of binding spec in let* : ((image) (buffer)) > >
> > I think this is due to changes in script-fu (?) but don't know enough
> > about script-fu to correct it. Could someone help?

This is explained in the release notes for GIMP 2.6: http://gimp.org/release-notes/gimp-2.6.html

Thanks ... I think :-) found the example and perused the linked PDF (section 4.2.2. Binding constructs) with out much if any understanding.

I changed: (define (save-layer orig-image layer name) (let* (
(image)
(buffer)
)

to:
(define (save-layer orig-image layer name) (let* (
(this-is-correct 0)
(image)
(buffer)
)

I'd expected that this would still choke on the (image) and (buffer) bindings (terminology(?)) so I guess that let* syntax just requires at least one variable-init pair?

Anyhow, it works now :-)

P.S.: Offtopic - I noticed in your reply that you sent it to "my address" with cc. to the list. I got only one copy (I think because Gmail suppresses the extra). Is it "good form" to just select ReplyAll and allow both to be sent. I've always tried to remember to delete the sender's email-address and send only To: thelist

Sven Neumann
2008-10-19 13:14:36 UTC (over 16 years ago)

script-fu-save-anim-layers

Hi,

On Sat, 2008-10-18 at 21:46 -0400, Alec Burgess wrote:

This is explained in the release notes for GIMP 2.6: http://gimp.org/release-notes/gimp-2.6.html

Thanks ... I think :-) found the example and perused the linked PDF (section 4.2.2. Binding constructs) with out much if any understanding.

I changed:
(define (save-layer orig-image layer name) (let* (
(image)
(buffer)
)

to:
(define (save-layer orig-image layer name) (let* (
(this-is-correct 0)
(image)
(buffer)
)

The proper fix would have been to use:

(let* ( (image -1)
(buffer -1)
)

The point is the variables need to be initialized on definition. I have chosen to initialize them to -1 in this example as that is the value that is used for an invalid image or buffer ID in GIMP.

Sven

Kevin Cozens
2008-10-19 22:02:26 UTC (over 16 years ago)

script-fu-save-anim-layers

Alec Burgess wrote:

Thanks ... I think :-) found the example and perused the linked PDF (section 4.2.2. Binding constructs) with out much if any understanding.

I changed: (define (save-layer orig-image layer name) (let* (
(image)
(buffer)
)

to:
(define (save-layer orig-image layer name) (let* (
(this-is-correct 0)
(image)
(buffer)
)

You didn't need to read the linked PDF file. That is there for reference in case someone doubted whether the Scheme interpreter in Script-Fu is doing "the right thing" regarding the let* blocks.

The release notes should have made it perfectly clear as to the problem and its fix. Since it appears the note about Script-Fu isn't clear enough I will think about some changes to the information. In the meantime, Sven has pointed out the needed changes to the script that were referred to in the release notes.

Alec Burgess
2008-10-20 00:06:57 UTC (over 16 years ago)

script-fu-save-anim-layers

Alec Burgess wrote:

Since we've had all these messages about this ... I thought I'd ask:

Shouldn't the so-called fix I made, adding a dummy variable with a value but leaving the remaining two variables (image) and (buffer) uninitialized still have been a syntax error? I was surprised that it in fact actually made the script work.

Kevin Cozens wrote:

Alec Burgess wrote:

Thanks ... I think :-) found the example and perused the linked PDF (section 4.2.2. Binding constructs) with out much if any understanding.

I changed: (define (save-layer orig-image layer name) (let* (
(image)
(buffer)
)

to:
(define (save-layer orig-image layer name) (let* (
(this-is-correct 0)
(image)
(buffer)
)

You didn't need to read the linked PDF file. That is there for reference in case someone doubted whether the Scheme interpreter in Script-Fu is doing "the right thing" regarding the let* blocks.

The release notes should have made it perfectly clear as to the problem and its fix. Since it appears the note about Script-Fu isn't clear enough I will think about some changes to the information. In the meantime, Sven has pointed out the needed changes to the script that were referred to in the release notes.