Skip to content

Instantly share code, notes, and snippets.

View yamahigashi's full-sized avatar

Takayoshi Matsumoto yamahigashi

View GitHub Profile
autoLoader.mll 1.463225366
autoLoader.mll 1.735383116
autoLoader.mll 2.210803252
autoLoader.mll 2.562135002
autoLoader.mll 2.616407629
autoLoader.mll 2.678918174
autoLoader.mll 2.762849043
autoLoader.mll 2.827423119
autoLoader.mll 2.866582192
autoLoader.mll 2.870142490
@yamahigashi
yamahigashi / add_custom_module_to_autorigs.py
Created March 24, 2017 10:13
Add custom rig-module to autorigs for SideFX Houdini
import os
import hou
from whereis.customModule import CustomModule
import autorigs.asset.moduleInfos as info
import autorigs.asset.defaultProperties as props
info.CUSTOM_MODULE_ICON = hou.ui.createQtIcon('OBJ_autorig', info.ICON_SIZE, info.ICON_SIZE)
info.MODULES_DATA.append(('custom', 'Custom', info.SPINE_ICON))
@yamahigashi
yamahigashi / toggleAnimCurveIsolation.mel
Last active April 7, 2025 11:46
toggle anim curve isolation state for Autodesk #maya Graph Editor
// mel
proc doToggleAnimCurveIsolation(string $outliner, string $ed)
// C:/Program Files/Autodesk/Maya2016.5/scripts/others/isolateAnimCurve.mel 参照
{
global int $gUnisolateJobNum;
if ($gUnisolateJobNum > 0) {
@yamahigashi
yamahigashi / register_command_into_submenu.py
Created December 2, 2016 03:56
Menu command registration method when its parent menu name can not be uniquely determined but its parent label is unique for Autodesk Maya
from functools import partial
import maya.mel as mel
import maya.cmds as cmds
cmd = '''
buildViewMenu MayaWindow|mainWindowMenu;
buildPreferenceMenu mainOptionsMenu;
string $parentName = "MayaWindow|mainWindowMenu";
@yamahigashi
yamahigashi / CalculateUpVector.py
Created July 20, 2016 07:30
upvector calculater for Autodesk Maya
# -*- coding: utf-8 -*-
"""
FK から アップベクタの位置を逆算
参考:
http://www.comtec.daikin.co.jp/DC/UsersNotes/Ritaro/tutorial/mobu_02/#1
"""
__author__ = 'yamahigashi'
__version__ = '1.0.0'
# ==================================================================================
--- C:/Qt/pyside-setup/PySide-1.2.4/sources/shiboken/shibokenmodule/typesystem_shiboken.xml.ori Fri Jul 01 17:40:27 2016
+++ C:/Qt/pyside-setup/PySide-1.2.4/sources/shiboken/shibokenmodule/typesystem_shiboken.xml Fri Jul 01 14:01:06 2016
@@ -3,7 +3,7 @@
<custom-type name="PyObject" />
<custom-type name="PyType" />
<primitive-type name="bool" />
- <primitive-type name="unsigned long" />
+ <primitive-type name="size_t" />
<add-function signature="isValid(PyObject*)" return-type="bool">
<inject-code>
@yamahigashi
yamahigashi / MASH1_Python.py
Last active April 6, 2017 20:02
exploration maya 2016 MASH feature for rigging.
import openMASH
from mash import MashVerletTest
mash_data = openMASH.MASHData(thisNode)
# --------------------------------------------------
# to hot reload "mash" module, uncomment this lines
# reload mash
# del MASH1_Python_solver # solver name, globals()['{}_solver'.format(thisNode)]
# --------------------------------------------------
# in maya
# -*- coding: utf-8 -*-
import re
import json
import maya.mel as mel
from maya.api import OpenMaya as OpenMaya2
import FabricEngine.Core as fe
@yamahigashi
yamahigashi / sticky_toggle_xformNoSelect.py
Last active March 30, 2016 11:56
for maya's hotkey runtime command, define commands key press begin, key press and key release within one command.
'''
# ショートカットキーを押した時、押している間、離した時に何かをするスクリプト
# このスクリプト起動時のキー押下状態保存してそのキーの持続状態を判定している
#
#  持続時間中に何かをするのでないのであれば、このようなスクリプトを使用するの
#  でなく素直に2つコマンド用意し同じキーに on press / on release としてそれぞれ
#  のコマンドを割り当てるほうが良い
#
#  winapi 使用するので win 専用
#
if (`selectPref -q -xformNoSelect` == true ){
selectPref -xformNoSelect false;
} else {
selectPref -xformNoSelect true;
}