GIMP Chat
http://gimpchat.com/

Python Scripts Working, But Python Plug-ins Not Showing on Mac
http://gimpchat.com/viewtopic.php?f=8&t=16065
Page 1 of 3

Author:  pawnee [ Tue Nov 28, 2017 10:59 pm ]
Post subject:  Python Scripts Working, But Python Plug-ins Not Showing on Mac

GIMP Version: 2.8.22
Operating System: Mac OS
OS Version: 10.11.6 El Capitan
GIMP Experience: Basic Level
URL or Image link: https://gimpscripts.com/2017/05/abstractart/

List any relevant plug-ins or scripts:
AbstractArt



Hello! I have a Mac (10.11.6 ~ El Capitan) and have played around with Gimp for a couple years (just easy stuff). Recently, I found the "world" of scripts and plug-ins...so cool! I'm interested in the AbstractArt plug-in. I downloaded it, put the DIEGO_ARTISTIC_AbstractArt.py file in the plug-in directory ($HOME/Library/Application Support/GIMP/2.8/plug-ins), made sure that directory was in my Gimp preferences (Gimp->Preferences->Folders->Plug-Ins), made it executable (chmod +x DIEGO_ARTISTIC_AbstractArt.py), restarted Gimp, and I cannot find it anywhere in the menu items. I've tried a number of different plug-ins with the same outcome. I was able to download and try several scripts, which all show up. What am I doing wrong?

Any help would be so appreciated!

Author:  dinasset [ Wed Nov 29, 2017 1:47 am ]
Post subject:  Re: Python Scripts Working, But Python Plug-ins Not Showing on Mac

Double-checked on Windows: it works.
Sorry, I'm not an expert on Mac.
Does this happen with ANY other .py plug-in you download/install?

Author:  dinasset [ Wed Nov 29, 2017 1:55 am ]
Post subject:  Re: Python Scripts Working, But Python Plug-ins Not Showing on Mac

ps: it makes use of plug-in Mosaic, do you have it running? (Filters/Distort/Mosaic...).
Also: it creates a new entry in Gimp Menu: Diego/Artistic; could this be an obstacle in Mac environment?

Author:  dinasset [ Wed Nov 29, 2017 2:09 am ]
Post subject:  Re: Python Scripts Working, But Python Plug-ins Not Showing on Mac

Maybe the "guru" Rich (Rich2005) could help?
Or someone else running Mac?

Author:  ofnuts [ Wed Nov 29, 2017 2:27 am ]
Post subject:  Re: Python Scripts Working, But Python Plug-ins Not Showing on Mac

1)Find your "Gimp profile", open the "pluginrc" file with a text editor, and look for the plugin file name. Is it there?
2) If not there, start Gimp in a terminal, and look for Python syntax error messages. If you edited the script you may have added spaces/tabs at the wrong place (if so, unpack the file again)

Author:  rich2005 [ Wed Nov 29, 2017 4:04 am ]
Post subject:  Re: Python Scripts Working, But Python Plug-ins Not Showing on Mac

Never a guru, just a devoted dabbler.

As well as Ofnuts checks, another one.

The stock Gimp installation already contains a few python plug-ins. A couple to see if they are in the menu.
foggify.py in Filters-> render -> clouds -> fog
text-brush.py in File -> Create -> New Brush From Text default gives a brush like a 'G'

If those are there and work, look at your installation procedure

One thing to check when making executable, is do you need the whole path?
chmod +x /path-to/DIEGO_ARTISTIC_AbstractArt.py

edit: Never-ever even used a Mac but once found this GUI utility for changing permissions.
http://www.lagentesoft.com/batchmod/
Any Mac users out there. I would love to know if it works, might help other users.

Author:  pawnee [ Wed Nov 29, 2017 9:27 am ]
Post subject:  Re: Python Scripts Working, But Python Plug-ins Not Showing on Mac

Thanks for the quick replies. I have gone through and tried your suggestions, but still having trouble.

I downloaded glass-text.scm and starry-sky.scm and they show up and work.

I have tried the following Python plug-ins:
DIEGO_ARTISTIC_AbstractArt.py
DIEGO_ARTISTIC_FakeVoronoi.py
DIEGO_ARTISTIC_PrintOnStones2.py
neon-pth-0.1.py

Only neon_pth-0.1.py is showing up in the pluginrc file, which was a great suggestion to look at.

I noticed that the file that unzipped was named "DIEGO_ARTISTIC_AbstractArt .py" (a space " " before .py), so I removed the space. I did not edit the file except for the name. I do have Filters->Distorts->Mosaic..., Filters->Render->Clouds->Fog..., and File->Create->New Brush From Text. The command "ls -l" is a way to check that the permissions are correct and they are.

I had tried downloading the latest Python, but removed that this morning, since I think these modules are installed with this level of Gimp. I also noticed that if I go to $HOME/Library/Application Support/ there were two Gimp folders, namely GIMP and Gimp-2.8. GIMP had a folder underneath that for 2.8. Since the preferences was using GIMP, I removed the Gimp-2.8 folder.

Thanks again!

Author:  ofnuts [ Wed Nov 29, 2017 10:26 am ]
Post subject:  Re: Python Scripts Working, But Python Plug-ins Not Showing on Mac

Gimp python scripts require Python 2.7.x.

Author:  dinasset [ Wed Nov 29, 2017 10:51 am ]
Post subject:  Re: Python Scripts Working, But Python Plug-ins Not Showing on Mac

Well, because all 3 of my filters try to register under the new menu entry "DIEGO/ARTISTIC", I have still the suspect that there could be a problem in creating a new menu entry in your Gimp.
If you don't mind, you may open the source using for instance notepad++, go to the menu statement (almost at the end) and replace
menu="<Image>/Diego/Artistic",
with
menu="<Image>/Filters/Artistic",
Let's see...

Author:  Zero01 [ Wed Nov 29, 2017 11:17 am ]
Post subject:  Re: Python Scripts Working, But Python Plug-ins Not Showing on Mac

Just a guess, but as the .py file is named "DIEGO_ARTISTIC_AbstractArt .py" (with the space), does that means the python file also needs to be unzipped, just a thought, it's possible to overlook the fact that it's a compressed file, unless that's just me (??)

Author:  dinasset [ Wed Nov 29, 2017 11:28 am ]
Post subject:  Re: Python Scripts Working, But Python Plug-ins Not Showing on Mac

Anyhow, the usual correct way for the user gimp folder is to have: (user)..gimp-2.8
and to put the link in Gimp/Preferences to that one.
Also it may be a good practice to create under .gimp-2.8 folder a sub folder for the additional plug-ins, named for instance "python_additional" or anything you prefer (for those 3 indicated you may also choose "python Diego") and link that subfolder

Author:  ofnuts [ Wed Nov 29, 2017 1:30 pm ]
Post subject:  Re: Python Scripts Working, But Python Plug-ins Not Showing on Mac

dinasset wrote:
Anyhow, the usual correct way for the user gimp folder is to have: (user)..gimp-2.8
and to put the link in Gimp/Preferences to that one.
Also it may be a good practice to create under .gimp-2.8 folder a sub folder for the additional plug-ins, named for instance "python_additional" or anything you prefer (for those 3 indicated you may also choose "python Diego") and link that subfolder

Doesn't need to be a subfolder, it can be anywhere.

Author:  pawnee [ Wed Nov 29, 2017 5:40 pm ]
Post subject:  Re: Python Scripts Working, But Python Plug-ins Not Showing on Mac

Changing the menu to <Image>/Filters/Artistic did not change anything and the file still doesn't show in the pluginrc file, but a good idea.

This is what is displayed when I bring up GIMP->Filters->Python-Fu->Console:

GIMP 2.8.22 Python Console
Python 2.7.8 (default, Jul 16 2016, 22:25:00)
[GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.57)]

Is there some way I can take the script and type it into the Console to see if it runs from a command line?

Again, a million thank you's to all of you for trying to solve this!

Author:  ofnuts [ Wed Nov 29, 2017 7:37 pm ]
Post subject:  Re: Python Scripts Working, But Python Plug-ins Not Showing on Mac

I'm still waiting for the results of starting Gimp in a terminal...

You can try to run it from a command line. If it says "ImportError: No module named gimpfu" this is normal (that module only exists when used from Gimp). But if you get another error, don't look further. But even with only the gimpfu complaint, you could have problems that only show once the script is started, hence the request above.

Author:  pawnee [ Wed Nov 29, 2017 8:00 pm ]
Post subject:  Re: Python Scripts Working, But Python Plug-ins Not Showing on Mac

Sorry, ofnuts...I thought you meant to run it from the terminal if I had edited the contents of the file. GIMP opened fine from the Terminal with no errors.

Can you tell me how I exactly run the DIEGO_ARTISTIC_AbstractArt.py it from the Python Console?

Thanks!

Author:  2-ton [ Wed Nov 29, 2017 9:05 pm ]
Post subject:  Re: Python Scripts Working, But Python Plug-ins Not Showing on Mac

I use a MAC, currently still using Yosemite (haven't upgraded because I heard that it would make Gimp behave badly), and have McGimp from Partha. I have found that most python scripts do not work in McGimp, except for a few that Partha included natively into it. He would be a good source of information on the subject, you can find his email (partha@partha.com) on his website...partha.com

Author:  dinasset [ Wed Nov 29, 2017 11:39 pm ]
Post subject:  Re: Python Scripts Working, But Python Plug-ins Not Showing on Mac

It can be executed by the Python Console using the following statements, having an open image:

>>> image = gimp.image_list()[0]
>>> layer = image.layers[0]
>>> gimp.pdb.python_fu_AbstractArt(image, layer, 0, 0, 0, 0, "nnnnnnnnn", 0, "nnnnnnnnn")

But I suspect that -if the filter does not show up in pluginrc- it will not be found

Author:  pawnee [ Thu Nov 30, 2017 7:25 am ]
Post subject:  Re: Python Scripts Working, But Python Plug-ins Not Showing on Mac

Huge update! I tried 2-ton's suggestion of downloading McGimp and all of the plug-ins magically showed up. :) The AbstractArt one that I had changed to <Image>/Filters/Artistic was found under Filters and all the others showed up under the main menu of Diego. I edited AbstractArt to fall under Diego. I'm having a few errors running it, but noticed that the McGimp standard edition link actually loaded the developmental release of 2.9.7. I have contact Partha about this to see if I can get a stable version for Mac.

Here are the errors:
Image
Image

I have no idea why these plug-ins are now showing up correctly on this version and are also showing up in the pluginrc, but I'm thrilled...even though they are not working, it's definitely progress! Thank you, thank you!

Author:  ofnuts [ Thu Nov 30, 2017 7:52 am ]
Post subject:  Re: Python Scripts Working, But Python Plug-ins Not Showing on Mac

pawnee wrote:
Huge update! I tried 2-ton's suggestion of downloading McGimp and all of the plug-ins magically showed up. :) The AbstractArt one that I had changed to <Image>/Filters/Artistic was found under Filters and all the others showed up under the main menu of Diego. I edited AbstractArt to fall under Diego. I'm having a few errors running it, but noticed that the McGimp standard edition link actually loaded the developmental release of 2.9.7. I have contact Partha about this to see if I can get a stable version for Mac.

Here are the errors:
[ Image ]
[ Image ]

I have no idea why these plug-ins are now showing up correctly on this version and are also showing up in the pluginrc, but I'm thrilled...even though they are not working, it's definitely progress! Thank you, thank you!


WHITE_FILL is defined in the "gimpfu" module and the script starts with the unavoidable "from gimpfu import *", so that must be a problem with Parth'a builds.

Author:  dinasset [ Thu Nov 30, 2017 8:38 am ]
Post subject:  Re: Python Scripts Working, But Python Plug-ins Not Showing on Mac

Good news, pawnee !

Edit: try replacing "WHITE_FILL" with "2" to have the filter running nonetheless.

Page 1 of 3 All times are UTC - 5 hours [ DST ]
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/