It is currently 20 Feb 2018, 23:25

GIMP Python Fu ScriptsReversed Copy Layer Stack script for GIMP (Showcase | Slideshow)

Share your Python Fu scripts for GIMP here
User avatar
tim

Administrator
View: Showcase | Slideshow
Topic Posts: 1/8
Posts: 2162
Joined: 26 Sep 2016, 00:16
Cash on hand: 7,946.37 GLP
Bank: 51,356.25 GLP
Gender: Guy
Location: Victoria, BC
Website: https://gimplearn.net
Operating System: Windows
GIMP Version: 2.8.22
My Personal Blog
My FineArtAmerica
x 1207
x 258
Contact:
Canada

Reversed Copy Layer Stack script for GIMP

Post#1 by tim » 27 Apr 2017, 23:23


This script was mentioned by Pat625.
I don't know if one already exists or not but here it is.
It simply makes copies of all your layers in reverse order and puts it on top of stack.
Could be used for reverse animation of some action such as a door opening, and this will create the door closing portion or vice versa.
:download:
reserved_copy_layer_stack.zip #
zipped .py file (unzip, put in your GIMP's /plug-ins/ folder)
(1.3 KiB) Downloaded 33 times
Script Menu location: Python-Fu/Reversed Copy Layer Stack

for example.
If you had a layer stack that looked like this.
layer_stack_before_reversed_copy_layer_stack_script.jpg
layer_stack_before_reversed_copy_layer_stack_script.jpg # (23.56 KiB) Viewed 477 times (Watermarked | Thumbnail)
After running script you'll get something like this.
layer_stack_after_reversed_copy_layer_stack_script.jpg
layer_stack_after_reversed_copy_layer_stack_script.jpg # (28.54 KiB) Viewed 477 times (Watermarked | Thumbnail)
1 x



aka Tin
Image gimplearn.net                                              

Registered members enjoy ads-free content
User avatar
Pat625
Script Tester
View: Showcase | Slideshow
Topic Posts: 2/8
Posts: 2232
Joined: 28 Sep 2016, 03:35
Cash on hand: 13,251.55 GLP
Gender: Gal
Location: USA
Operating System: Windows
GIMP Version: 2.8.22
x 8
x 470
United States of America

Post#2 by Pat625 » 28 Apr 2017, 03:44


Thank you very much, Tin. I am sure to use it.
0 x




User avatar
dinasset
Script Coder
View: Showcase | Slideshow
Topic Posts: 1/8
Posts: 718
Joined: 20 Jan 2017, 11:50
Cash on hand: 3,537.35 GLP
Gender: Guy
Location: Roma (Italy)
x 91
x 128
Italy

Post#3 by dinasset » 28 Apr 2017, 04:21


Excellent tool for animation.
Thanks to Pat who "invented" the sequence and to Tim who simplified the life!
0 x




User avatar
Pat625
Script Tester
View: Showcase | Slideshow
Topic Posts: 2/8
Posts: 2232
Joined: 28 Sep 2016, 03:35
Cash on hand: 13,251.55 GLP
Gender: Gal
Location: USA
Operating System: Windows
GIMP Version: 2.8.22
x 8
x 470
United States of America

Post#4 by Pat625 » 28 Apr 2017, 19:18


Thank you, Dinasset, but I did not "invent" the sequence. The original map fold idea was brought to GimpChat from one of its members who had it translated from another language. The first I saw the return to original position was by Tin when he did the Map Fold Animate script:
http://gimpchat.com/viewtopic.php?f=9&t ... 7&start=30.
0 x




User avatar
Steve Reid
Script Coder
View: Showcase | Slideshow
Topic Posts: 2/8
Posts: 74
Joined: 20 Jul 2017, 10:55
Cash on hand: 872.36 GLP
Gender: Guy
Location: Barrow in Furness
Operating System: Windows
GIMP Version: 2.9.5
x 37
x 13
Gimp Nation

Post#5 by Steve Reid » 21 Jul 2017, 06:00


Neat script, this will save a lot of duplication then raising/lowering of layers, as no matter how careful I try to be there is always one layer that ends up out of sequence
0 x




User avatar
Ella
Tutorial Creator
View: Showcase | Slideshow
Topic Posts: 2/8
Posts: 757
Joined: 27 Feb 2017, 10:16
Cash on hand: 8,124.60 GLP
Gender: Gal
Operating System: Windows
GIMP Version: 2.9.5
x 44
x 405
Belgium

Post#6 by Ella » 21 Jul 2017, 12:35


Steve Reid wrote:
21 Jul 2017, 06:00
as no matter how careful I try to be there is always one layer that ends up out of sequence
That's weird. I used the script several times and never had that problem.
Do you select the very top layer before using the script?
0 x



There is a crack in everything. That's how the light gets in.
(Leonard Cohen)

User avatar
Steve Reid
Script Coder
View: Showcase | Slideshow
Topic Posts: 2/8
Posts: 74
Joined: 20 Jul 2017, 10:55
Cash on hand: 872.36 GLP
Gender: Guy
Location: Barrow in Furness
Operating System: Windows
GIMP Version: 2.9.5
x 37
x 13
Gimp Nation

Post#7 by Steve Reid » 21 Jul 2017, 13:26


Sorry Ella :oops: , what I meant was before finding this script I would duplicate and position layers manually, and I usually got one or more wrong, this script copies and positions them perfectly, sorry for any confusion, my bad. :)

I am going to adapt it slightly, take layers a, b, c and d

d
c
b
a

running the script gives

a
b
c
d
d
c
b
a

adapt the script to give

b
c
d
c
b
a

This runs through a loop that doesn't have double start and end points
0 x




Post Reply

Last 20 Members Who Visited This Topic

User avatar gnerd (2), User avatar Pat625 (6), User avatar animicule (2), User avatar tim (4), User avatar RJKD (3), User avatar Ella (5), User avatar Steve Reid (4), User avatar Issabella (1)

  • Similar Topics
    Replies
    Views
    Last post
• Featuring Members' Works (Image Attachments Only) •
1: Conbagui
2: Issabella
3: Pat625
4: Pat625
5: Issabella
6: animicule
7: Ella

Who is online

Users browsing this forum: No registered users and 3 guests