0
我已經使用MEL中的addNewShelfTab和scriptToShelf命令爲我的迷你Mel腳本創建圖標。我希望能夠像使用MEL或Python一樣從Shelf Editor中更改默認圖標。我怎麼能這樣做呢?使用mel或python更改貨架上mel腳本的圖標
我已經使用MEL中的addNewShelfTab和scriptToShelf命令爲我的迷你Mel腳本創建圖標。我希望能夠像使用MEL或Python一樣從Shelf Editor中更改默認圖標。我怎麼能這樣做呢?使用mel或python更改貨架上mel腳本的圖標
shelfButton -edit -image1 "icon.png" $name;
以下Python腳本爲我工作:
import maya.mel as mel
import pymel.core as pm
mel.eval('addNewShelfTab($shelfName)');
pm.shelfButton(annotation='Annotation', image1=$image, command='<command>');