Created
September 23, 2015 16:18
-
-
Save TSCG/4c6eb8e0d2a860357bec to your computer and use it in GitHub Desktop.
Texture Resolution Edit / Maya
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Viewのテクスチャ表示を一時的に変更 | |
//マテリアルを選択して実行 | |
//引数:解像度サイズ | |
global proc TsSetTexRes(int $TexRes){ | |
int $moto = `displayPref -q -maxTextureResolution`; | |
displayPref -maxTextureResolution $TexRes; | |
string $infoName[] = `listConnections -type materialInfo`; | |
for( $tmp in $infoName){ | |
string $TexName[] = `listConnections -type file $tmp`; | |
disconnectAttr ($TexName[0] + ".message") ($tmp + ".texture[0]"); | |
connectAttr -force ($TexName[0] + ".message") ($tmp + ".texture[0]"); | |
}; | |
refresh ; | |
displayPref -maxTextureResolution $moto; | |
} | |
//usage | |
//TsSetTexRes(4096); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment