Enter Ritalin, a Python script that will automatically set your camera's tumble pivots when the selection changes in the scene, and even when your selection is moved. Special case handling has been added for convenience that centers the tumble pivots on the currently active deformer (e.g. joint) when painting skin weights on a mesh, which is a huge time saver when painting hard to see or detailed areas like a character's fingers, where a considerable amount of time is usually spent on adjusting the camera in such a way that it tumbles without constantly loosing the paintable area out of sight, and where pressing f on your keyboard usually doesn't help because it will center on the selected mesh, not the active deformer.
Lots of text to describe such a simple thing right? A short video shows a lot better how it looks and feels like.
If that video looks cut off on the right you might want to watch it on youtube directly:
http://www.youtube.com/watch?v=RmFiOkboAR0
Result:
You will find yourself not having to press "f" so often anymore, camera pivots are centered completely automaticlally, and your viewport "calms down" a lot. Your eyes and poor little f key will be eternally grateful, let alone the time you can save and concentrate on more important things, like creating art for a change.
Installation:
1.) Download http://keyvis-dev.googlecode.com/files/RitalinForMaya_2008-2010_1.4.zip
2.) Unpack and copy the files to your user scripts directory.
In WindowsXP this folder is normally normally located at
C:\Documents and Settings\-YourUserName-
A Ritalin menu should appear in the main menu bar. You can disable or re-enable Ritalin there.
There's also an option to disable skin weight painting integration separately.
For TD's:
It is important that the Ritalin'ed version of it gets sourced after Maya has sourced the original file from its native ...\scripts\others folder for the code change to take effect.
If you are using a modified version of this file in your own pipeline you might want to add the extra lines to the same function in your version of the file instead of replacing the whole file. In case this is not practical, simply not copy the file at all, you will simply have to live without paint skin weights tool panel integration (clicking on a deformer in the paint tool panel will not center the camera's tumble pivot on it automatically). However, you will still be able to use Ritalin when right-clicking over a deformer in th viewport and choosing "Paint Weights" from the context menu to set the tumble pivots. Anything else will work normally.
Uninstall:
In case you have modified your userSetup.py file, comment out, or remove, the line you copied into it too.
Disclaimer:
it is a shame that many users seem to be unaware of that treasure . i have asked billion times of that functionality in forums but a bunch of people could guess what i talked about . thanks million times
ReplyDeleteThe reason ritalin is mostly unknown is that I haven't made a lot of noise around it. Also, many are unaware of other programs that have this feature for years(max,softimage,lw) and don't see how they could benefit from it. Glad you like it. There is also an update for Maya 2011 btw.
ReplyDeleteExperienced a problem with version 1.4 in Maya 2011 x64 on Win7; 8GB RAM. Ritalin when enabled causes the undoQueue to turn off repeatedly. In preferences, undo is set to infinite.
ReplyDeleteThe previous version of Ritalin worked a charm in Maya 2010. Any ideas on a fix? Thanks!
I will have a look. I'm using 2011 32 bit at work still and haven't managed to repro what you describe. I hope it's not a 64bit only thing/bug (in which case I couldn't do much to fix it).
ReplyDeleteIt would make testing easier on my side if you could describe a few steps with good reproducability. Also, what Maya service pack are you currently using?
Hi Stefan,
ReplyDeleteYeah, conversely I haven't tested this in maya 2011 x86 on my machine. I'm running maya 2011x64 hotfix 3.
I've tried to find a pattern in this behaviour - a trigger. Tumbling the view or selecting a rig control will do it.
Have tried blowing away my maya prefs. And weeding out all mels and adding them back piecemeal.
Here is a link to my public Dropbox folder: http://db.tt/UUlKa7
The zip file contains a screencap and the script editor output in echoAllCommands. Hope it helps towards a fix or to exonerate Ritalin.
Thanks!!
Right, I was able to repro using a different approach. It turned out this happens due to a bug introduced by Autodesk in Maya version 2011, but I think I found a way to work around it. Here's the update: http://plutometro.blogspot.com/2010/08/ritalin-hotfix-for-maya-2011.html
ReplyDeletePlease try and let me know how it goes.
Can someone please explain how to get this to work on a Mac in Maya 2010/2011?
ReplyDeleteI've tried setting the path to "/Users/Shared/Autodesk/maya/2011/scripts/Ritalin_Public.py", but when I launch the Maya application, Ritalin doesn't seem to appear.
Any assistance with this would be most appreciated. Thanks in advance!
In Finder, press shift-command-g. Paste this directory path: ~/Library/Preferences/Autodesk/maya/ In the resulting Finder window, open the folder for your maya version, eg. 2011-x64. Then open the scripts folder. Drag a copy of Ritalin's .py files into here.
ReplyDeleteSelect Ritalin_Public.py and press command-i for Get Info. Copy the text of the directory path beside "Where". It will look like this: /Users/USERNAME/Library/Preferences/Autodesk/maya/VERSION/scripts/Ritalin_Public.py
Close out of Get Info. Right-click on userSetup.py and select Open With…, then choose or browse to Textedit. Once userSetup.py opens in Textedit, replace the directory path for Ritalin_Public.py with the directory path text you just copied from Get Info. Make sure the result is still encased in quotations inside the brackets. Save userSetup.py and close out.
Fire up Maya and your good to go!
Thanks for the fix Stefan! All good now.
ReplyDeleteHi Stefan ,
ReplyDeletei am using ritalin i am happy with its functions . but maya still cant reach in the taste of max navigation . is there a way to convert it to max's navigation .
thanks in advance
Hi Anonymous, Could you elaborate a bit more on what exactly it is that you miss? When you write that it's not exactly as in Max, do you mean the keyboard shortcuts which are different?
ReplyDelete