This section describes the functionality of the example plug-ins distributed with Maya.
A large number of example plug-ins is supplied with the Maya Developer Kit. The Developer Kit is available online at Autodesk Exchange at https://apps.exchange.autodesk.com/MAYA/en/Home/Index.
For information on how to set up your build environment to build the examples, see Setting up your build environment.
Examples can be divided into 4 categories:
Find these in the devkit\plug-ins folder.
Find these in the devkit\plug-ins\scripted folder. See Scripted plug-ins.
Find these in the devkit\dotnet folder. See Compiling .NET examples.
Find these in the devkit\applications folder. See Standalone applications.
In general, the following naming convention is used by the examples so you can identify the kind of plug-in the example based on its file name.
Scripted plug-ins in the Maya Developer Kit demonstrate the use of the proxy classes of the Maya Python API 1.0 and 2.0. Python API 2.0 example plug-ins begin with py, so for example the 2.0 version of the helloWorldCmd.py plug-in is called pyHelloWorldCmd.py. Not all API 1.0 plug-ins have 2.0 versions, and vice versa.
Shader source code examples, such as brickShader, checkerShader, gammaShader, and so forth, are available in the devkit\plug-ins. The examples cover both hardware shaders, which are used when rendering in Maya's scene view, and software shading nodes, which are used when rendering using Maya's Software renderer.
Software shading nodes are, in general, not compatible with third-party renderers. These renderers may pick up, from the shading nodes, specific output values which are constant throughout a frame, but for values which change on a per-object, per-vertex or per-sample basis, they require shaders written in their own APIs.
Standalone applications are those that contain the main routine for the application and make API calls to access Maya in batch mode. They are compiled in a slightly different manner than plug-ins (as covered in Using a debugger to debug your plug-ins), but utilize the same API as plug-ins, and in the same way.
If these variables are not set, you will get errors when you attempt to start a stand-alone application.