NOTE: This page was valid until Maya2OSG 0.4.2c. For newer releases or SVN trunk, check the new page [Building_and_installing]
To use the Maya2OSG plug-in, the following dependencies must be installed in the system:
This software has been tested on the following environments, although not all of these project files are currently included or maintained:
Change to the directory of the Maya version you intend to compile the plug-in for and then to the corresponding (or nearest) Visual Studio folder.
NOTE: Current distribution is tested with Visual Studio 2008 Express Edition, although it should work perfectly in Visual Studio 2008 and later versions.
Add to
Tools > Options > Projects and Solutions > VC++ Directories
the
bin
,
include
and
lib
directories of the installed Maya SDK and OSG libraries. Current Visual Studio project try to install the plug-in (
maya2osg.mll
) in the plug-ins directory of Maya in its default location (e.g.
C:\Program Files\Autodesk\Maya 2010\bin\plug-ins
). However, it can fail in some systems (such as Windows Vista or Windows 7) because of file permissions, so check it.
Additional files (MEL scripts, shelf buttons, ...) will also be automatically installed in the current user Maya default directory.
A fast workaround to the above mentioned permission problem is to give modification access to the plug-ins directory for the user that is doing the compilation.
Change to the directory of the Maya version you intend to compile the plug-in for and then to the Linux folder. Execute GNU makefile to compile the plug-in.
For example, the Maya 2010 plug-in for Linux can be built just type:
$ cd wherever_it_is/maya2osg/maya2010/Linux
$ make
and it will create the
wherever_it_is/maya2osg/maya2010/bin/maya2osg.so
file.
**WARNING: Some Maya versions have a bug in
maya/MFnDependencyNode.h
header file that prevented compilation with g++ (it works perfectly with Visual C++). It is a missing semicolon (;) after the line reading**
declareMFn(MFnDependencyNode, MFnBase)
This issue was solved in Maya 2011.
The compiled plug-in will be stored in the
bin
directory under the directory for the chosen Maya version. It will be
maya2osg.mll
in Windows and
maya2osg.so
in Linux.
Wiki: Building_and_installing
Wiki: Compilation_instructions_(deprecated)