Pose based rig caching for Maya
📺 Watch a demo of Hyperdrive on Youtube
🔨 Experimental: This is a personal research project and not yet production ready
Hyperdrive is a Pose-based character rig caching solution for Autodesk Maya 2017 / 2018.
It's heavily inspired by the pose-based rig caching solution developed and presented by Disney Animation at Siggraph 2015: "Achieving Real-Time Playback with Production Rigs"
Unlike common caching approaches available in DCC applications, this approach doesn't rely on time-based geometry caching. Instead it is utulizing the character rig animation values to calculate a unique pose ID, which points to a certain set of deformed character meshes stored in the cache. These poses are frame independent and can be re-used across different frame-ranges and even animation scenes.
For further details on my different approaches to solve to pose-based caching in Maya, please check out my Hyperdrive blog post.
- CentOS 7 / Fedora 26+ (Windows currently untested)
- Autodesk Maya 2017 / 2018 with SDK installed
- Git
- CMake - Version 3.9.1 or newer
Hyperdrive comes with a CMake script that makes building the plugin fairly simple.
I recommend using CMake GUI if you are not familiar with the CMake command line interface.
-
Clone the repository using Git to a directory of your choice.
-
Open CMake GUI and choose the cloned directory as your source code root.
-
Press Configure. The output widget should show you which Maya SDK versions were found.
-
Press Generate. This will generate the make script.
-
Navigate to the repository root in your favorite shell and execute the make install command to build the plugin. Make sure to change the -j argument to the available CPU core count on your machine.:
make install -j8
-
Clone the repository using Git to a directory of your choice.
-
Run the CMake command to generate the make script. The console output will show, which Maya SDK versions were found.
cmake /path/to/hyperdrive/repo
-
Execute the make install command to build the plugin. Make sure to change the -j argument to the available CPU core count on your machine.:
make install -j8
After successfully building the plugin, all you need to do is to point Maya to the Hyperdrive module.
export MAYA_MODULE_PATH=/path/to/hyperdrive/repo:&
Launch Maya. After Maya has finished loading, you should see a Hyperdrive menu in the main window. If you are missing this menu for some reason, please make sure that the plugin is available to Maya and loaded. You can do this via Windows - Setting/Preferences - Plug-in Manager.
To launch the Hyperdrive GUI, click Hyperdrive - Manager in the main menu. This will open the Manger UI, which is your central hub to use Hyperdrive.
- Open Hyperdrive Manager and click Add Rig. Enter a unique Rig Tag for your setup. Ideally this is the character name AND a version number. You need to update your Rig Tag everytime your Rig changes.
- Select your character meshes and click Add Mesh in the Caches Tab. This will create a HdCacheNode for each mesh and connect them to your HdPoseNode.
- Select your animation controls and click Add Control Attrs. in Controls. Hyperdrive connects your animation controls to the pose node of the rig and you are good to go.
- Optional: Use the Blacklist / Whitelist tabs to add nodes to be explicitly evaluated all the time / never.
To temporarily bypass the cache after the setup, go to Settings and check Bypass.
-
Install the necessary Python packages.
$ pip install sphinx sphinx-rtd-theme exhale recommonmark
-
Navigate to
path\to\hyperdrive\repository\docs
and execute the make command.$ make html
-
The built documentation is in
path\to\hyperdrive\repository\docs\_build\html
.
- Meshes sometimes lose material on scrubbing.
- For some complex rigs, animation edits of already cached regions might lead to inaccurate re-caching.
- Sometimes pose node to cache node connections are not being stored properly (in file), even though they appear correctly in the node editor.
- Sometimes Cache setups created via GUI do not trigger Maya to update the cacheId. The cache node needs to be disconnected and reconnected to fix this.
- The evaluator sometimes fails to update it's internal state when the scene changes.
- Meshes attached via follicle or constraints may result in incorrect cache geometry.
- M3dView currently breaks build on Linux so support for status text in viewport is not possible.
- The current prototype works best when being used with a bunch of smaller meshes instead of one big mesh (this is a Maya drawing limitation).
- Using a lot of cached meshes results in less and less performance gain.
- Whitelisting / Blacklisting nodetype instead of specific nodes
- Log to file
- Cache to file
- Draw caches with OpenGL directly
- Draw Hyperdrive state text in viewport
- Hyperdrive: My approach to pose-based rig caching in Maya
- "Achieving Real-Time Playback with Production Rigs"
- Parallel Processing within a Host Application
- Using Parallel Maya 2018
- Siggraph 2017: Parallel Evluation of Animated Maya Characters
- Around The Corner - Maya Development Blog
This project is relying on some awesome open source code to work.
MIT License
Written by Tim Lehr
Copyright (c) 2019 Animationsinstitut of Filmakademie Baden-Wuerttemberg
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.