It is currently Sat Jul 20, 2024 8:28 pm


All times are UTC - 5 hours [ DST ]



Post new topic Reply to topic  [ 11 posts ] 
Author Message
 Post subject: Create Layer Mask from...
PostPosted: Thu Aug 30, 2012 12:19 pm  (#1) 
Offline
GimpChat Member
User avatar

Joined: May 14, 2012
Posts: 10
Image

GIMP 2.8 Python Plug-in.
This plugin allows you to create layer mask from another layer mask.
Or create layer mask from grayscale copy of layer.

Installation:
1. Extract "create-layer-mask-from.py" from zip archive to the ".../.gimp-2.x/plug-ins" directory.
2. If you're on a UNIX system, make sure "create-layer-mask-from.py" is executable.
3. Once you have saved the file in your plug-ins folder, if you are already running GIMP, close and reopen it.
4. If you have done this correctly, the scripts will appear in the menu under: "<Image>/Layer/Mask/Create Layer Mask from..." and "<Layers>/Create Layer Mask from...".

Download:
Download from my deviantart page:
slybug.deviantart.com

Tested with GIMP 2.8.
I hope this plug-in will be useful for someone else.

Version History:
v1.0 (30.08.2012)
- Initial release.

My other plugins:
Duplicate to another Image
Layer via Copy/Cut
Scale Layer to Image Size


Last edited by slybug on Mon Apr 22, 2013 8:35 am, edited 1 time in total.

Share on Facebook Share on Twitter Share on Orkut Share on Digg Share on MySpace Share on Delicious Share on Technorati
Top
 Post subject: Re: Create Layer Mask from...
PostPosted: Thu Aug 30, 2012 4:19 pm  (#2) 
Offline
GimpChat Member
User avatar

Joined: May 16, 2010
Posts: 14715
Location: USA
Thanks Slybug. :)

_________________
Image
Edmund Burke nailed it when he said, "The only thing necessary for the triumph of evil is for good men to do nothing."


Top
 Post subject: Re: Create Layer Mask from...
PostPosted: Thu Aug 30, 2012 4:31 pm  (#3) 
Offline
GimpChat Member
User avatar

Joined: Jul 17, 2012
Posts: 2770
i worked a lot with layermasks, they are a very useful technique, but i have no idea what this script does and what i could with it

why would i want to create a layermask from another layermask ??

apologies, if thats a stupid question
but any explanation would be really helpful


Top
 Post subject: Re: Create Layer Mask from...
PostPosted: Thu Aug 30, 2012 4:35 pm  (#4) 
Offline
Global Moderator
User avatar

Joined: Apr 07, 2010
Posts: 14182
I am glad you asked it Esper, cuz I thought the same so now there is two with the same stupid question.

_________________
Image


Top
 Post subject: Re: Create Layer Mask from...
PostPosted: Thu Aug 30, 2012 8:07 pm  (#5) 
Offline
Script Coder
User avatar

Joined: Oct 25, 2010
Posts: 4757
... and what is wrong with copy/paste of the layer mask between layers?

_________________
Image


Top
 Post subject: Re: Create Layer Mask from...
PostPosted: Fri Aug 31, 2012 12:53 pm  (#6) 
Offline
GimpChat Member

Joined: Apr 12, 2010
Posts: 5870
ofnuts wrote:
... and what is wrong with copy/paste of the layer mask between layers?


Not sure what may be wrong but every time i tried didn't worked

_________________
My 3D Gallery on Deviantart http://photocomix2.deviantart.com/
Main gallery http://www.flickriver.com/photos/photocomix-mandala/
Mandala and simmetry http://www.flickriver.com/photos/photocomix_mandala/

Image

Mrs Wilbress


Top
 Post subject: Re: Create Layer Mask from...
PostPosted: Fri Aug 31, 2012 1:09 pm  (#7) 
Offline
Script Coder
User avatar

Joined: Oct 25, 2010
Posts: 4757
PhotoComix wrote:
ofnuts wrote:
... and what is wrong with copy/paste of the layer mask between layers?


Not sure what may be wrong but every time i tried didn't worked

Make mask of source layer the active drawable
Edit/Copy
Add empty mask to target layer
Make mask of target layer the active drawable
Edit/Paste -> creates floating selection
Layer/Anchor -> Floating selection becomes mask of target layer

Complete no-brainer if both layers are the size of the canvas. If the layers are equal size but smaller than the canvas and at different coordinates, the paste adjust itself to the target...

_________________
Image


Top
 Post subject: Re: Create Layer Mask from...
PostPosted: Fri Aug 31, 2012 3:46 pm  (#8) 
Offline
GimpChat Member
User avatar

Joined: May 14, 2012
Posts: 10
Rod wrote:
Thanks Slybug. :)

You're welcome Rod! :)

Esper wrote:
but any explanation would be really helpful

The main feature of this plug-in - is an option that allows you to change the interaction between two masks (Add, Subtract...).

Image

Otherwise, the plug-in just a little speeds up the process of copying mask from one layer to another.
So... each to his own :)
Sorry for my english...


Top
 Post subject: Re: Create Layer Mask from...
PostPosted: Fri Aug 31, 2012 4:26 pm  (#9) 
Offline
GimpChat Member

Joined: Apr 12, 2010
Posts: 5870
i appreciate that speed up i hate copy, paste ,anchor ,also because even if is a trivial process always something go wrong when i do with layer mask (basically it refuse to anchor on the mask but only accept to get pasted to the layer .) ,so i am happy for a script speeding up the process.

_________________
My 3D Gallery on Deviantart http://photocomix2.deviantart.com/
Main gallery http://www.flickriver.com/photos/photocomix-mandala/
Mandala and simmetry http://www.flickriver.com/photos/photocomix_mandala/

Image

Mrs Wilbress


Top
 Post subject: Re: Create Layer Mask from...
PostPosted: Fri Aug 31, 2012 5:30 pm  (#10) 
Offline
Script Coder
User avatar

Joined: Oct 25, 2010
Posts: 4757
PhotoComix wrote:
i appreciate that speed up i hate copy, paste ,anchor ,also because even if is a trivial process always something go wrong when i do with layer mask (basically it refuse to anchor on the mask but only accept to get pasted to the layer .) ,so i am happy for a script speeding up the process.

Because you have to be editing the target mask (and not the layer) at the time when when you paste.

_________________
Image


Top
 Post subject: Re: Create Layer Mask from...
PostPosted: Fri Aug 31, 2012 6:30 pm  (#11) 
Offline
GimpChat Member

Joined: Apr 12, 2010
Posts: 5870
not sure if i was editing but i am sure i took care it was the active thing in that moment ...but of course you are right is doable and i should have goofed and done some dumb deviation from the correct steps...
but still i am happy to have not to try again because a script that could take care

_________________
My 3D Gallery on Deviantart http://photocomix2.deviantart.com/
Main gallery http://www.flickriver.com/photos/photocomix-mandala/
Mandala and simmetry http://www.flickriver.com/photos/photocomix_mandala/

Image

Mrs Wilbress


Top
Post new topic Reply to topic  [ 11 posts ] 

All times are UTC - 5 hours [ DST ]


   Similar Topics   Replies 
No new posts Create Layer Mask From

8

No new posts Attachment(s) PYTON-FU-CREATE-LAYER-MASK-FROM...

3

No new posts Add layer mask hides the entire layer

3

No new posts Automating Layer mask application

4

No new posts Attachment(s) MAKING A PERFECT ELLIPSE FOR LAYER MASK

6



* Login  



Powered by phpBB3 © phpBB Group