Dear Andrew,
apparently the new version of Maya includes a custom version of Python,
which is built with the Visual Studio 2010 compiler (version 16) and the
MSVCR10 C runtime library. The standard CPython 2.6 distribution, and
almost all existing extension package binaries, use the Visual Studio
2008 compiler and the MSVCR90 C runtime library.
The correct solution would be to build PIL with the Visual Studio 2010
compiler and link against the custom python26.lib from Maya.
As a workaround you could try to provide an external msvcr90 manifest
file for the existing PIL pyd extensions. This might not work correctly
because the use of different C runtime libraries in one process can
cause crashes or memory corruptions.
Christoph
On 8/17/2011 6:24 AM, andrew_seym...@scee.net wrote:
Hi,
I've integrated PIL into some of our tools for Maya. In particular I use
it to create 16bit TIFFs.
In Maya 2010 64 bit which I believe uses Python 2.6.1 everything worked
fine. I got compiled versions of PIL from:
http://www.lfd.uci.edu/~gohlke/pythonlibs/
<http://www.lfd.uci.edu/~gohlke/pythonlibs/>
which worked great.
I'm now preparing to move to the latest version of 64bit Maya which I
believe uses Python 2.6.4.
I'm having problems with importing the _imaging module.
With the path added to the system path I first got this error:
# Error: ImportError: file <maya console> line 7: DLL load failed: The
specified module could not be found. #
I then used dependency walker to try and find out what was missing. I
then tried to include a 64 bit version of msvcr90.dll in the PIL directory.
This resulted in the following error:
# Error: ImportError: file <maya console> line 1: DLL load failed: A
dynamic link library (DLL) initialization routine failed. #
Windows Error:
Microsoft Visual C++ Runtime Errror!
R6034
An application has made an attempt to load the C runtime library
incorrectly.
Please contact the application's support team for more information.
Looking a little deeper PIL worked fine in 64 bit with Python 2.6.4 that
I installed for windows from the python site:
Installed: *Python 2.6.4 (r264:75708, Oct 26 2009, 07:36:50) [MSC v.1500
64 bit (AMD64)] on win32*
But, with Maya the compiled python included looks slightly different:
Maya: *Python 2.6.4 (r264:75706, May 19 2011, 13:53:43) [MSC v.1600 64
bit (AMD64)] on win32*
Would this be the reason behind the issues, and if so is there a process
I can follow to fix it?
I personally don't have the know how or software to compile PIL locally
as I am a Technical Artist and not a fully blown programmer, so any help
would be greatly appreciated.
Can you help or advise?
Andrew Seymour
Principal Technical Artist
Sony Computer Entertainment Europe Limited
http://eu.playstation.com <http://eu.playstation.com/>
**********************************************************************
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they are
addressed. If you have received this email in error please notify
postmas...@scee.net
This footnote also confirms that this email message has been checked for
all known viruses.
Sony Computer Entertainment Europe Limited
Registered Office: 10 Great Marlborough Street, London W1F 7LP, United
Kingdom
Registered in England: 3277793
**********************************************************************
P */Please consider the environment before printing this e-mail/*
_______________________________________________
Image-SIG maillist - Image-SIG@python.org
http://mail.python.org/mailman/listinfo/image-sig
_______________________________________________
Image-SIG maillist - Image-SIG@python.org
http://mail.python.org/mailman/listinfo/image-sig