The Pymel documentation currently tells you to type:
from pymel import *
But the latest release (1.0.0.rc1) will not work with this method on a new installation. We've tested it on about a dozen machines and so far all of them require a slight change, which is to type the following:
from pymel.core import *
There may be a simple work-around for this, but if you follow the installation instructions from scratch on a machine with no previous installs, you will need to do this to get the pymel modules to import into Maya.
What is Pymel? From the site:
Python in Maya Done Right
PyMEL makes python scripting with Maya work the way it should. Maya's command module is a direct translation of mel commands into python commands. The result is a very awkward and unpythonic syntax which does not take advantage of python's strengths -- particulary, a flexible, object-oriented design. PyMEL builds on the cmds module by organizing many of its commands into a class hierarchy, and by customizing them to operate in a more succinct and intuitive way.
Check out the Pymel website for more information.
http://code.google.com/p/pymel/
No comments:
Post a Comment