How mgear-dev/mgear works
Project Type and Purpose
• mGear is a modular rigging and animation framework developed for Autodesk Maya.
• Its purpose is to provide a set of modules, tools, and C++ solvers to streamline the development of rigging and animation tools.
• The system integrates Python-based modules (for UI, tools, and higher-level rig functionality) with performance-critical C++ plugins (solvers, custom nodes, etc.) to work within Maya.
Main Components
a. Autodesk Maya Environment:
• Maya as the host environment where mGear is loaded as plugins and scripts.
• Connection between Maya’s API and the mGear components.
b. mGear Framework – Python Modules:
• mGear Core: Includes utilities, attribute management, logging, callbacks, and other general-purpose functionalities (contents found in release/scripts/mgear/core and similar folders).
c. C++ Plugins (Solvers and Performance-critical Nodes):
• “src” directory components, which contain various C++ source files for plugins (solver nodes, constraint nodes, etc.).
• That these components are built with CMake (driven by CMakeLists.txt and associated cmake scripts) and loaded into Maya as custom plugins.
• That they interact with the mGear framework by providing computation-heavy operations (e.g., spring solvers, matrix operations).
d. Build, Deployment, and Versioning:
• Integration of GitHub workflows, CMake build scripts, and release packaging.
• How the CI/CD components (located in .github/workflows and build scripts) feed into building, testing, and deploying both Python scripts and C++ plugins.
Relationships and Interactions
• Link the mGear Python modules to the underlying C++ plugins, illustrating that some functions (e.g., solvers, custom nodes) are implemented in C++ to enhance performance.
• Documentation and test suites as support layers interfacing with the core modules.
Highlighting Architectural Patterns and Design Principles
• Modular structure: each rigging module (e.g., Shifter, Rigbits, Anim Picker) is separated but interconnected through shared utilities found in mGear Core.
• Separation between the user interface layer (Python UI scripts and corresponding Maya commands) and the computational layer (C++ solvers).
• Stress the plugin-based design that allows mGear to be extensible and future-proof for upcoming Maya versions.