I'm looking to build a script using Gimps build in Python extension.
I have run into a problem though, and these are my symptoms, perhaps someone here is able to help me.
When I run Python-fu from Gimp I get what you would expect, and a clear indication that everything is working.
System details: Win10 - 64 bit
Gimp 2.8.22 Python.exe - version 2.7 (the one included in Gimp installation and seperate install to be sure)
Gimp message:
GIMP 2.8.22 Python Console
Python 2.7.10 (default, May 23 2015, 09:40:32) [MSC v.1500 32 bit (Intel)]
>>> sys.path
['C:\\Program Files\\GIMP 2\\lib\\gimp\\2.0\\plug-ins',
'C:\\Program Files\\GIMP 2\\32\\lib\\gimp\\2.0\\python',
'C:\\Program Files\\GIMP 2\\Python\\python27.zip',
'C:\\Program Files\\GIMP 2\\Python\\DLLs',
'C:\\Program Files\\GIMP 2\\Python\\lib',
'C:\\Program Files\\GIMP 2\\Python\\lib\\plat-win',
'C:\\Program Files\\GIMP 2\\Python\\lib\\lib-tk',
'C:\\Program Files\\GIMP 2\\Python',
'C:\\Program Files\\GIMP 2\\Python\\lib\\site-packages',
'C:\\Program Files\\GIMP 2\\Python\\lib\\site-packages\\gtk-2.0',
'C:\\Program Files\\GIMP 2\\Python\\lib\\site-packages']
>>> gimp
<module 'gimp' from 'C:\Program Files\GIMP 2\32\lib\gimp\2.0\python\gimp.pyd'>
However when I run a script with that entire path included, from the python.exe file I get:
C:\Python27\python.exe D:/P5/m-cworkshop/Sprites2d/spritofu.py Traceback (most recent call last): File "D:/P5/m-cworkshop/Sprites2d/spritofu.py", line 2, in <module> from gimpfu import *
File "C:\Program Files\GIMP 2\32\lib\gimp\2.0\python\gimpfu.py", line 76, in <module>
import gimp
ImportError: DLL load failed: Det angivne modul blev ikke fundet. (Translation edit!: The indicated module was not found)
Process finished with exit code 1
So its clearly able to pick up the gimpfu.py file, but not the gimp.pyd file right next to it.
Here is what i have been able to verify so far:
My python installations are 32 bit.
This happens on both my computers.
This happens no matter how many things I include in the path, as long as I include the gimpfu.py
path.