![]()
Überware
<info@uberware.net>
|
These are the scripts I've written or modified to make my life with Maya that much more
pleasant. Note that there aren't many here. I use many more scripts, of course,
most of which I've downloaded from Highend 3d.
Check out Smedge, my cool render queueing system for Maya. You can join the mailing list for this page, and get an update whenever I add or change a script!
This script generates a marking menu with the quick selection sets. It is customized to work with the selectionEditorWin script, though you don't need this script for the other to work. Usage: Place this script into your personal .../maya/scripts/ directory. I re-assigned the q key to bring up this script, since I never use any of the default selection marking menus. Look in the Window|Settings/Preferences|Hotkeys for the exact syntax for mapping the keys to the marking menus.
When I was first using Maya, I found it terribly annoying to have to remember to change the project every time I opened a scene in a different project. But if you don't then, rendered images can end up in the wrong project's image directory. Since I work with a lot of projects it can get quite confusing. Usage: I placed the following line into my userSetup.mel: scriptJob -e SceneOpened confirmProjChange;This way, anytime I open a scene, this script runs. It checks to see if the scene is in a different project than the one I was working in before. If so, it asks if I would like to change the project. Requirements: This script now works on both IRIX and NT. It requires Maya 2.0 or greater.
Now that we've got some NT boxes, we've got projects that need to render across both platforms. since all of our disks are shared across machines, the only problem is mapping the IRIX "/usr" format to the NT "C:" format. This script does the mapping. Usage: call the function conformTextures Also, you can put the conformTextures command into your pre-render MEL field of your scene's Render Globals. That way, no matter which machine created the scene, any machine can render it. Instructions for customizing the mappings are included in the file. Requirements: This script requires Maya 2.0 or later.
This script automates a lot of the tedium of setting up an image plane. The coolest thing that it does is that if you select the Browse button, you can double click on any image in a sequence, and it will automatically find the first and last frames, and set your image plane frame extension correctly. It has a bunch of options and a few limitations. Be sure to look through the help window for full details. Usage: call the function imagePlaner Notes: The autodetection generally requires a sequence of image files in any of the Alias|Wavefront formats (e.g., name.1, name.0001.rla, name.iff.1, etc.) It won't work with a movie file. But you can always type in the frame range by hand.
The frame sequencing can be done by either keyframes or an expression. See
the help window for full details.
If you have a complex skeleton, this command lets you set keyframes on the rotate attributes of every joint without having to select every joint. Just set up your skeleton with a parent node that has the word "Skeleton" somewhere in it. Then, when you execute this command, it will keyframe every joint under that parent node. Usage: select any joint in the skeleton, then call the function keyframeHierarchy I have mapped this to Alt+k
We've all done it: pressed save when we didn't mean to, and overwrote the good file with the crap we've been messing around with. To avoid this, I have hacked together this little script. All it does is execute a shell command to copy the scene to a "comma file" a la the old TAV style (e.g. "scene.mb" becomes ",,scene.mb"). Usage: Put the script in your scripts/ directory, then add the following line to your userSetup.mel file: scriptJob -ro true -cf "busy" "source makeBackup.mel"; The script will override the default FileMenu_SaveItem proc to make the backup before saving. Note: This script should work with both IRIX and NT. It requires Maya 2.0 or later.
A really simple multi-object renaming script. Usage: Select a bunch of objects then type: renamer newName The objects will be named newName1 newName2 etc...
Maya has both a playback range and an animation range. This script only adjusts the playback range. It also integrates itself into the Render Globals window to allow you to set the render range to the current playback range, the animation range, or to any of the defined sections. Just right click on either the Start or End frame fields. The Add button creates a new section. The default values are pulled from the current frame range. The text in the Description field can be anything you like. You can then select one of your sections, and use the Set button to set that section to the current frame range. The ? button is a help button, and, of course, Delete deletes the sections. Usage: Call the function "sectionList" To integrate into the Render Globals window, you should add the following line to your userSetup.mel file: source renderGlobalsWindow.mel; scriptJob -ro true -cf "busy" "source sectionList.mel"; Notes:
Usage: call the function "selectionEditorWin" This script inserts itself into the Edit menu in the Quick Select Sets submenu. To implement this functionality, add the following line to your userSetup.mel file: scriptJob -ro true -cf "busy" "source selectionEditorWin.mel";
Notes:
Because Layers have customized hooks into Maya, undo/redo and imorting or
referencing files works beautifully. Well, it works just the same with these
sets, but the window doesn't update correctly. You have to manually update
the window with the Update button or by closing and re-opening it.
The default Maya hide/show functionality is flawed and becomes a pain. This script simply toggles the visibility attribute of the objects passed to it. If they have to visibility attribute, nothing happens. Usage: toggleVisibility $arrayOfItems I have mapped toggleVisibility `ls -sl` to Control+h.
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||