Layer Effects

This is a series of scripts that implement various layer effects:

  • Drop Shadow
  • Inner Shadow
  • Outer Glow
  • Inner Glow
  • Bevel and Emboss
  • Satin
  • Color Overlay
  • Gradient Overlay
  • Pattern Overlay
  • Stroke

Some effects can have contours (a.k.a. curves) and noise added to them. Effects can either be applied on a separate layer, or be merged into the active layer (which in some cases gives better results).

Tested with GIMP 2.4.2.

Updated 6/9/2009:

  • Stroke now supports gradients and patterns! (Python version only)
  • Better undo handling in the Python version.
  • Various bugfixes.

Updated 11/15/2008:

  • The Python version now has live previewing! With the "Preview" checkbox active, the preview now updates automatically every time you change a setting!
  • New "Reapply Effects" function: Reapplies all effects that have been applied to the current layer. If you change anything on the layer, use this to update all the effects in one go! (Mind you, this only works for effects that were not applied using the "Merge with layer" option.)
  • Various bugfixes.

Updated 09/02/2008:

  • Bugfix in Script-Fu version.

Updated 07/19/2008:

  • You can now scale patterns in pattern overlays. (Python version only.)

Updated 07/08/2008:
This script has now been rewritten as a Python plugin! This adds several new features that weren't possible in Script-Fu!

  • You can now preview effects! Click the "Preview" button to see what it will look like with the currently selected settings.
  • The plugin now records the settings used to make an effect, so now you can reapply it! Run the same effect plugin on the same layer again, and it recovers the previous settings for that layer and shows them in the dialog box. You can then change the settings and apply the effect again, and it will replace the original effect layer! (Note: This will only work if you don't select "Merge with layer". Once an effect has been merged into the layer, it can't be removed or changed.)

Updated 04/21/2008:

  • Bugfix

Updated 03/02/2008:

  • Added grayscale support
  • Bugfixes

How to install (Script-Fu version):

  1. Right-click on the link below that says "layerfx.scm". A pop-up menu should appear. Click "Save Target As..." or "Save Link As..." or whatever the equivalent option in your browser is.
  2. Save the file "layerfx.scm" in your scripts folder. If you're not sure where your scripts folder is, you can check by opening GIMP and going to <Toolbox>/File/Preferences -> Folders -> Scripts. If more than one folder is shown, then any one of them will work.
  3. Once you have saved the file in your scripts folder, if you are already running GIMP, either click <Toolbox>/Xtns/Script-Fu/Refresh Scripts, or just close and reopen GIMP.
  4. If you have done this correctly, the scripts will appear in the menu under <Image>/Script-Fu/Layer Effects. If this menu is not there, try clicking <Toolbox>/Xtns/Script-Fu/Refresh Scripts. If it's still not there, make sure the file is in your scripts folder and that the filename ends with ".scm", not ".txt" or ".scm.txt" or something.

How to install (Python version):

  1. Right-click on the link below that says "layerfx.py". A pop-up menu should appear. Click "Save Target As..." or "Save Link As..." or whatever the equivalent option in your browser is.
  2. Save the file "layerfx.py" in your plug-ins folder. If you're not sure where your plug-ins folder is, you can check by opening GIMP and going to <Toolbox>/File/Preferences -> Folders -> Plug-Ins. If more than one folder is shown, then any one of them will work.
  3. If you're on a UNIX system, make sure layerfx.py is executable by typing this in the shell:
    chmod +x layerfx.py
    On other operating systems, you might have to do something else to make it executable.
  4. Once you have saved the file in your plug-ins folder, if you are already running GIMP, close and reopen it.
  5. If you have done this correctly, the scripts will appear in the menu under <Image>/Layer/Layer Effects, and <Layers>/Layer Effects. If these menus are not there, close and reopen GIMP. If they're still not there, make sure the file is in your plug-ins folder, that it is executable, that you have Python support installed, and that the filename ends with ".py", not ".txt" or ".py.txt" or something.
AttachmentSize
layerfx.scm55.46 KB
layerfx.py267.55 KB

Comments

Problems with effect when layer has no fully transparent area

I have Gimp 2.6, with Python enabled, and all the necessary cruft to get the Python plugin working. I noticed after installing it that although the script will run and report success, like a few others here I end up with no actual output - just empty layers above the layer I was attempting to apply an effect to.

I found that if the layer has no *completely* transparent areas, the plugin can't produce an effect. For instance, if I create a new image, and want to apply an inner glow or inner shadow to the background layer - which has no transparency, though it does have an alpha channel, I can run the script, but nothing happens. After adding an alpha channel per an earlier comment, I still get nothing. This happens in both the python and scm versions of the plugin.

However, if the image has a completely transparent portion - even one pixel - the plugin will work as expected and produce the effect. It's only if you're trying to apply an effect to a layer without a completely transparent area that it seems to fail. Is this a bug, or just something I don't understand about how these effect work? I don't know enough about scm or python to even guess where the problem might be.

Thanks,
Chris

By the way, don't use

By the way, don't use layer effects plugins(gimp-registry-plugins package) from ubuntu repository -- seems like they old there and don't work(or work very strange).

Works like a dream (so far ;)

This has just enriched my GIMP experience incredibly. Thanks!!

Python Script Version Runs but Not Modifying Anything.

Using: GIMP 2.6.11/XP Svc Pk 3/python 2.6 installed/python features in GIMP installed.

Problem: The python script executes and runs; and the status bar in GIMP reports various things that the python script is doing. When the script finishes running, however, all I have as a result of running the python script is a blank, transparent, layer above the layer I tried to modify. In other words, the python script is executing; but apparently nothing is happening -- i.e., the image remains unchanged, and the end result is that I have a blank, transparent layer added above the layer I am trying to modify with the python version of the script.

This does not occur with the Script-fu version of the program.

What am I doing incorrectly? I would like to have the python script up and running so that I can avail myself of the "preview" feature.

Any insight or assistance with which you might be able to provide me will be greatly appreciated.

Thank you,

Nuncus

Try entering different

Try entering different parameters in the dialog box, maybe?

Inner shadow only on half of layer

gimp 2.6.11-3+b1 from Debian wheezy
gimp-plugin-registry 3.5.3 from Debian wheezy

When I apply Inner Shadow to a layer, it only seems to operate on one side of the image. I've tried different combinations of settings and it's always the same region.

This screenshot say it all: http://i.imgur.com/VESgu.png

I am unable to reproduce this

I am unable to reproduce this error.

another helpful win 7 tip

if you are having issues with the script right click properties on gimp, select compatibility tab, and set it to windows xp, also click use program as admin. once you have done that You can save the script to c: users gimp script.

New Feature - Auto update with reference layer?

I have been thinking if there is a new feature planned for this plugin - auto update.

Let me explain it with an example. Let's say I have created a text layer "Foo Bar". I then apply Layer Effect > Stroke on this layer. If this is done correctly with current version of this plugin, a layer of stroke is created and added above the text layer. Now, the following is the main point I want to say: If I now want to change the text layer's text to "Fool Bar", the previously created stroke layer will not change/update itself to adapt the new change.

I think it would be nice, as a new feature, that when I update the reference layer, the layer effect will also update automatically, without having me to redo the layer effect again each time.

I am bringing this idea up is that I am quite used to Photoshop's fx effect on layers, and not surprisingly, when I update the layer content, the layer effect will also update itself on PhotoShop. I think it will be really helpful and save a lot of time if this plugin can achieve the same too.

Yeah, that would be a great

Yeah, that would be a great feature, but as far as I know it's not possible at the moment. I'm hoping this GEGL stuff they're working on will make it possible to implement this capability in a future version of GIMP.

Problem with adding the SCM file

Hello all,

I have experienced problems when adding the SCM file. I have resolved the problem but I think it'd be good to share this.

I am using Windows 7 64-bit and GIMP 2.6.8. I read the instruction about installing the SCM file. So I just picked a directory and put the SCM file into:
C:\Program Files (x86)\GIMP-2.0\lib\gimp\2.0\scripts

I followed the instruction but the menus do not show up.

I then tried the python version. Similarly, I put the PY file in:
C:\Program Files (x86)\GIMP-2.0\lib\gimp\2.0\plug-ins

It does not work either.... I tried restarting GIMP so many time and nothing works. I also played with python settings, adminitrator access, etc... but nothing works...

I then tried another approach. I simply put the SCM file in:
C:\Users\\.gimp-2.6\scripts

...and it works!

So I would like someone to correct the SCM install instructions above "If more than one folder is shown, then any one of them will work.". Obviously, it doesn't work in the one in program files but only works in the one in user folder. I haven't tried the python version yet but I guess it's similar case that it's not "any one of them will work".

I hope this comment helps.

the instrution were correct

even if is better place extra script and plugin in the user gimp folder, as you did in your last attempt ,they should work even if placed in the gimp script folder in Program Files

May be some weird peculiarity in that script or your machine (..mainly with win 7 could be weird permission problems preventing the changes you did (add a script) to be applied, that may explain what happened to you ) but the instrution were right...

.

Cannot get python script to work

I would appreciate your help.
Windows 7 Enterprise 64 bit

Installed Python 2.6 plus modules necessary.

Installed GIMP using the advanced set up so that the Python Modules could be ticked.
Installed Layer Effects in Script-Fu successfully.

Cannot get the python to work.
In the Filters -> Python-Fu-Console menu is there. However, if I click on it, nothing happens. The Script-Fu Console opens if clicked.

What have I done wrong please?

Thanking you in advance.

Layer effects py - german description

Hi all

a german description for Windoof can you find under:

http://gimp-atelier.org/forum/viewtopic.php?p=785#p785

loves from Germany

Avarra

Anti-Alias option?

Many can appreciate this script/plug-in, myself included, but is there a way to add anti-alias option to the various layer styles?

Color Issues

I was wondering if anyone else had trouble with the color of the overlays. Specifically, all of the overlays I've used have been desaturated. I don't know if I'm missing a selection, but I've trued changing all the settings I could find. If anyone has any suggestions, they would be greatly received.

Not playing nice with Gimp 2.7.x

/*======*/
Ubuntu 10.0.4 Lucid
Gimp v2.7.1

Installed Gimp 2.7 - http://www.howtogeek.com/howto/12047/install-gimp-2.7.1-on-lucid-lynx-us...

Added layerfx.py to Gimp plugin folder with (right click) Permissions => 'Allow executing file as program' can now find it in the Layers menu.

However trying to use any of the effects results in errors in the gimp console, or if you ignore the errors most of the effect don't work.

GIMP Warning
WARNING: Plug-In "layerfx.py"
(/home/[username]/.gimp-2.7/plug-ins/layerfx.py)
called deprecated procedure 'gimp-drawable-parasite-list'.
It should call 'gimp-item-parasite-list' instead!

/*======*/ Update...
Ubuntu 10.0.4 Lucid
Gimp v2.7.1

I've just compiled Gimp 2.7 so I can run 2.6.x and 2.7.x. Just tried layerfx in 2.7.x and works perfectly. So something must be wrong in the link of the ppa version above.

/*======*/
Ubuntu 10.0.4
Gimp 2.6.11

Still works! :)

/*======*/
Windows 7 x64
Gimp 2.7.1

After I got this installed (installing python and various other addons) everytime I tried to run layerfx it crashed Gimp.

/*======*/
Windows 7 x64
Gimp 2.6.11

Still works!

/*======*/
For Ubuntu I'm not sure if this is a compile difference 2.7.x and 2.6.x which is why it doesn't play nice with 2.7.x. Hopefully someone will get this awesome time saving script updated just a shame it can't be added to Gimp forever!

try the script version

I think, you tried to use ".py" file, and it doesn't works. Try to download the ".scm" file and paste into the "scripts" folder.
You'll find the layer effects in the menu "Script-Fu"

The description says, that Script-Fu version is basically for windows, but it's not. Works fine under Linux.

I hope it helps.

Not sure what 2.7.x you are

Not sure what 2.7.x you are using
in the most recent from Git you will see that NONE of the third party plugin would work,
and even the plugin included (bundled)in gimp 2.6 will never work if transferred on 2.7 and vice versa.

not sure if is the same for py scripts but from the error messages you posted seems so.

not even sure if will be worth adapt the script to 2.7 because more changes are still possibles, changes that may break again the script

Recently installed Python

Recently installed Python (Windows) GIMP and going back and looking for some cool Python plugins. Excellent by the way. Thanks for sharing. :)

what is shell?

I am a newbie in Linux. you said:

If you're on a UNIX system, make sure layerfx.py is executable by typing this in the shell:
chmod +x layerfx.py

my question is, what is shell? where can I find it? thanx :-)

= terminal the thingy you

= terminal
the thingy you type command in

Better 2.7/2.8 integration?

Hi!

Thanks for an incredibly useful plugin. Now that I've compiled and installed Gimp from GIT, and seen the new features there, I have some suggesitons:
- Add an option for grouping effects with the current layer (layer groups). This will make it easier to work with many effects and layers.
- The gradient settings don't work. For example gradient strokes.

Would that be possible?

Thanks.

Layer grouping

maybe you will like this http://www.registry.gimp.org/node/16563

It is quite complex to set up but works well

Hopefully similar options would have a better integration in gimp 2.8 but in the while i believe it can satisfy your needs

I'd rather not have to deal

I'd rather not have to deal with development versions, since things could change a lot or be only partially implemented. Once 2.8 is released, we'll see.

installing python version

Hi, I have installed both scrpt versions, the scm before and now the python. but while the scm version is installed correctly (I see all script under script-fu->effects Layer, in the python version under Layer-> Layer Effects bevel and emboss, Drop shadows, Outer Glow, Satin and Stroke menus are disabled. May suggest some solution?

Other question, it is possible localize it in italian and if yes how?

Thank you very much

Those all require the layer

Those all require the layer to have an alpha channel. Select a layer with an alpha channel and they should work.

disabled means that the menu

disabled means that the menu is grayed out or that the script does not show up in the menu??

In case you use Windows do you know that gimp support to python is not enabled by default but require some fiddling?

see here for the fiddling ..http://www.registry.gimp.org/node/186#comment-6914

only some menus are greyed.

only some menus are greyed.

Yes, I have installed activestate and the other modules before installing
The Layers plugin

did you reinstalled gimp

First i believe you need python NOT "active python"
( I packed everything needed time ago anyway now there is a more updated Gimp-python pack from "gimptricks" on www.deviantart.com )

Then is also needed reinstall gimp using the "Customize" option of the installer ,and there chose the enable python option

Maybe you did since the menu are visible even if grayed out

If so more commune reason for grayed out menu are

1)No image open
2 )Image mode not compatible (most plugin works only with RGB and RGBA images, but not with index or greyscale ...
so not with gif or scannered BW)

Solution for 1 is obvious..for 2 is Image/image mode/rgb

Windows Vista Home Premium Gimp 2.6.8

This is how i installed this plugin...

Tried the scm it didnt work gave error about missing parenthesis or somethign like that. So installed the python version instead like so..(its not hard just a few steps to install some compnents)

Uninstall Gimp
Go to http://www.python.org/download/
Install Python 2.6.4

Go to http://www.pygtk.org/downloads.html
Install PyCairo 1.8
Install PYGObject 2.2
Install PYGtk 2.16
reboot (may not be necessary but i like to reboot often...let the machine know who is the boss..
)
Install Gimp -( select custom install and make sure python option is checked It was checked by default after i installed python components)

Put the layerfx.py file in your gimp plugins folder as described in the directions above.

Restart Gimp and it should be in your Layers menu at the bottom.

Im a newbie at gimp so i just tried drop shadow it made a drop shadow so it works.. now i just have to learn how to use gimp.

cheers!! (open source programmers are modern day heroes!! :-)

about python

okay i had follow all of the directions with installing it, now when its comes to the gimp, i go to custom so i can do the check lists, rite there for some reason the python section will not let me check it....what am i doing wrong..HELP!!!!

Python version doesn't work with GIMP 2.7 in Ubuntu 9.10

as subject. GIMP version 2.7.1 and Ubuntu 9.10.
Python 2.6.4
The menu don't show up with layerfx.py (only with script-fu version)
Everything's fine with 2.6
Any solution for this? (this plug-in is a must)
Thanks in advance

It's able to do!!!!!

you have to download the layerfx.py (now it's in the Downloads folder)
2. open the terminal and switch with the command : cd Downloads : into the downloads folder
3. type in : sudo chmod aug+rwx layerfx.py
4. user@username:~/Downloads$ will apear
5. open your filemanager as a root type in terminal : gksudo nautilus : and put the custom data layerfx.py in this folder : /usr/lib/gimp/plug-ins
6. reopen GIMP and that is it !!!

I hope my english is good enough to understand!!! xD

error log

(gimp:4775): LibGimpBase-WARNING **: gimp: gimp_wire_read(): error
Traceback (most recent call last):
File "/usr/lib/gimp/2.0/plug-ins/py-slice.py", line 30, in
from gimpfu import *
ImportError: No module named gimpfu

(gimp:4775): LibGimpBase-WARNING **: gimp: gimp_wire_read(): error
Traceback (most recent call last):
File "/home/marcoz/.gimp-2.7/plug-ins/layerfx.py", line 23, in
import gimp, gimpplugin, math, re
ImportError: No module named gimp

(gimp:4775): LibGimpBase-WARNING **: gimp: gimp_wire_read(): error

The first error is repeated for lots of functions...

Follow these instructions...

I had the same errors, but followed these instructions, and now the Python version of layerfx works fine in gimp 2.7:

http://ubuntuforums.org/showthread.php?p=9129490

I need help

I downloaded the python version to my mac, but I don't see the "layer effects".
I keep getting this message:
Last login: Sat Dec 26 02:16:44 on ttys000
luke-kims-computer:~ lukekim$ cd '/Applications/Gimp.app/Contents/Resources/lib/gimp/2.0/plug-ins/' && '/usr/bin/pythonw' '/Applications/Gimp.app/Contents/Resources/lib/gimp/2.0/plug-ins/layerfx.py' && echo Exit status: $? && exit 1
Traceback (most recent call last):
File "/Applications/Gimp.app/Contents/Resources/lib/gimp/2.0/plug-ins/layerfx.py", line 23, in
import gimp, gimpplugin, math, re
ImportError: No module named gimp
luke-kims-computer:plug-ins lukekim$

Can someone help me?

Download Script-Fu on Mac

I can't get this to download on my mac. Can anyone give me more concrete steps. I put the Script-Fu in my resources folder of Gimp but it won't open. It looks like a blank box. Any help? Thanks

Just to let you know, I

Just to let you know, I noticed that on my Mac, Layer Effects has moved to Layer -> Layer Effects. It's not in the Filters menu. :D

Did Gimp on Mac support

Did Gimp on Mac support python plugin ?
Do you used successfully other script with the ".py" extension ?

In case there is a different version of the script in Scheme (extension .scm) that will work on every OS

DRop Shadows forget they r linked when U save and reopen a file.

ANy help is appreciated here:

I work with dailly template files that I alter every day. I would like to be able to add a drop shadow to all my text layers once, then simply re-open the file, and 'Reapply Effects' to those layers, and have the drop shadow update to match the new text..

This does not work, once i save/close/reopen a file, GIMP forget that the newly created drop shadow layer below my text is associated with the text layer, and of course, get the standard error message of:

Reapply Effects Warning
Error: No effects found on this layer.

GIMP Warning
Plug-In 'Reapply Effects' left image undo in inconsistent state, closing open undo groups.

The "reapply effects' function only appears to work if have JUST created a Drop shadow.....but does NOT function after you close the file..

Can anyone help me with this issue?
Thanks!!!

Ed

Thanks! Now some suggestions :D

Hey. Love the plugin. Thank you so much.
Been using it for some time now, and I have a suggestion or so.

I bug/problem I noticed with he bevel is: Unless 'merge with layer' is selected, inner bevel blurring goes outside the lines. If the size is greater than 0, then it will bleed into the surroundings.

Also, unless there is a size greater than 0, there are lines in the bevel. Maybe use a faint blur or even 'selective guassian blur' to the bumpmap layer before use?

I'd also like to see a soften/blur option for inner/outer glow.

Another problem I noticed is (at least with outer glow): If an effect is performed on an invisible layer, that layer then becomes visible. I know this seems like a small thing, but sometimes I have to apply an effect to many invisible layers (see end of post).

Again, love the plugin. Here's some stuff I made with it:
http://cheeseenthusiast.deviantart.com/art/Surge-Xion-skin-138554091
http://cheeseenthusiast.deviantart.com/art/Thrine-xion-skin-138971961

please show how you did that

can you please show us what settings you used to build your designs. no matter what settings I use in gimp, I do not see the inner shadow or bevel emboss expanding richly as it should around objects.

thanks

Scaling effect?

Would you please, please, pretty please add a scaling / cropping effect? I'm tired of Gimp edit operations that permanently alter my source image. I took several days and learned Scheme so I could make a Layer Groups feature, which Miguel has nicely added on to, but it might take me weeks to learn Python.... I'm willing to try but any help would be appreciated.

GIMP already has scaling and

GIMP already has scaling and cropping tools.

Python version not working in GIMP 2.7.0/Windows Vista

I downloaded the python version of this plug-in, copied it to my plug-ins directory (with the .py extension) as you said...but when i open an image in GIMP I don't see the "Layer Effects" menu under the "Image/Layer/" menu. I have GIMP 2.7.0, Windows Vista and Python 2.6.2 installed. Other applications that use Python (eg. Blender) work fine.

It works with Gimp 2.7.0 (Vista)

Tested with Gimp 2.7.0 and Python 2.6.2 Link : http://www.aljacom.com/~gimp/download.html Start Gimp with gimp_en_anglais_disque_dur.bat

Um...

Yeah, when I right-click the link, the "Save Target As" won't let me click it. Help?

Use a different browser?

Use a different browser?

The same problem with *.py in Windows Vista

Hi, i have tha same problem. In Vista PY-script loaded by started GIMP 2.6.7 but in Image > Layer - i do not see this. Sorry (bad english).
Syndicate content