本文整理匯總了Python中maya.api.OpenMaya.MPxCommand方法的典型用法代碼示例。如果您正苦於以下問題:Python OpenMaya.MPxCommand方法的具體用法?Python OpenMaya.MPxCommand怎麽用?Python OpenMaya.MPxCommand使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類maya.api.OpenMaya
的用法示例。
在下文中一共展示了OpenMaya.MPxCommand方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: maya_useNewAPI
# 需要導入模塊: from maya.api import OpenMaya [as 別名]
# 或者: from maya.api.OpenMaya import MPxCommand [as 別名]
def maya_useNewAPI():
# It doesn't need to do anything so we'll just pass inside it
pass
# We need to build out our command and we do this by inheriting from the base MPxCommand that defines commands
# MPx prefixes denote classes we are meant to inherit from
示例2: __init__
# 需要導入模塊: from maya.api import OpenMaya [as 別名]
# 或者: from maya.api.OpenMaya import MPxCommand [as 別名]
def __init__(self):
global siweighteditor
from siweighteditor import siweighteditor
''' Constructor. '''
om2.MPxCommand.__init__(self)