maya贴图路径找回脚本(5)

2019-01-10 13:14

FTM_Log \ break; } $progress = $i; $percentage = $progress * 100 / size($Nodes); progressWindow -e -pr $progress -st (\filter type, please wait...... \+ $percentage + \ string $cmd = \ if (catchQuiet(eval($cmd))) FTM_Log \\\\\\is locked/connected and can NOT be modified!\ else FTM_Log \ } progressWindow -ep; FTM_Log \ FTM_END; waitCursor -state off; } }

////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////// //

// Command for BOT setup //

global proc FTM_BOTSetup(int $FTM_BOTMode, string $FTM_ExtraFunctionColumn) //$FTM_BOTMode - 1 Setup // - 0 Unset {

string $FTM_FileNodes[]=`ls -sl -typ file`; if (`FTM_SelCheck $FTM_FileNodes`) { waitCursor -state on; FTM_Log \ int $progress = 0; int $percentage = 0; progressWindow -t \Working...\-pr $progress -ii 1 -min 0 -max `size $FTM_FileNodes`; for ($i=0; $i

break; } $progress = $i; $percentage = $progress * 100 / size($FTM_FileNodes); progressWindow -e -pr $progress -st (\ \$percentage + \ // Do not handle sequence textures if (`getAttr ($FTM_FileNodes[$i] + \ FTM_Log \ continue; } int $resolution = `intFieldGrp -q -v1 ($FTM_ExtraFunctionColumn + \ float $xRes = `getAttr ($FTM_FileNodes[$i] + \ float $yRes = `getAttr ($FTM_FileNodes[$i] + \ if ($FTM_BOTMode) {// Setup if ($xRes >= $resolution || $yRes >= $resolution) { string $FTM_File = `getAttr ($FTM_FileNodes[$i] + \ $FTM_File = `substituteAll \ string $FTM_TheBOT = `substitute \ string $BOTCmd = \ -r \\ if (catchQuiet(eval($BOTCmd))) FTM_Log \or the BOT file already exists.\ string $cacheCmd = \ string $pathCmd = \-typ \\\\+ $FTM_FileNodes[$i] + \ if (catchQuiet(eval($cacheCmd))) FTM_Log \and can NOT be modified!\ else if (catchQuiet(eval($pathCmd))) FTM_Log \\\Attribute \\\is locked/connected and can NOT be modified!\ else FTM_Log \ } else FTM_Log \specified threshold, skipped!\ }

else {// Cancel if ($xRes <= $resolution && $yRes <= $resolution) { string $cacheCmd = \ string $FTM_File = `getAttr ($FTM_FileNodes[$i] + \ $FTM_File = `substituteAll \ $FTM_File = `substitute \ string $pathCmd = \-typ \\\\+ $FTM_FileNodes[$i] + \ if (catchQuiet(eval($cacheCmd))) FTM_Log \and can NOT be modified!\ else if (catchQuiet(eval($pathCmd))) FTM_Log \\\Attribute \\\is locked/connected and can NOT be modified!\ else FTM_Log \ } else FTM_Log \specified threshold, skipped!\ } } progressWindow -ep; FTM_Log \ FTM_END; waitCursor -state off; } }

////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////// //

// Command for mentalray memory-mapped texture (.map) setup //

global proc FTM_MAPSetup(int $FTM_MAPMode, string $FTM_ExtraFunctionColumn) //$FTM_MAPMode - 1 Setup // - 0 Unset {

string $FTM_FileNodes[]=`ls -sl -typ file`; if (`FTM_SelCheck $FTM_FileNodes`) { waitCursor -state on; FTM_Log \ int $progress = 0; int $percentage = 0;

progressWindow -t \Working...\-pr $progress -ii 1 -min 0 -max `size $FTM_FileNodes`; for ($i=0; $i= $resolution || $yRes >= $resolution) { string $FTM_File = `getAttr ($FTM_FileNodes[$i] + \ $FTM_File = `substituteAll \ string $FTM_TheMAP = `substitute \ string $MAPCmd = \-p -r \\\\\\\+ (encodeString(`toNativePath $FTM_File`)) + \\\\\\\\+ (encodeString(`toNativePath $FTM_TheMAP`)) + \ if (`file -q -ex $FTM_TheMAP`){ // .map is already there. FTM_Log \\(\memory-mapped texture file \\\+ `toNativePath $FTM_TheMAP` + \ } else { if (catchQuiet(eval($MAPCmd))) FTM_Log \failed. Could be permission issue or 'imf_copy' can not be found in system executable path.\ } string $pathCmd = \-typ \\\\+ $FTM_FileNodes[$i] + \ if (catchQuiet(eval($pathCmd)))

FTM_Log \\\Attribute \\\is locked/connected and can NOT be modified!\ else FTM_Log \\\memory-mapped texture setup accomplished.\ } else FTM_Log \specified threshold, skipped!\ } else {// Unset if ($xRes <= $resolution && $yRes <= $resolution) { string $FTM_File = `getAttr ($FTM_FileNodes[$i] + \ $FTM_File = `substituteAll \ string $FTM_TheMAP = $FTM_File; $FTM_File = `substitute \ int $wrong = 0; if (!`file -q -ex $FTM_File`){ FTM_Log \\ FTM_Log \\\\ string $UnMAPCmd = \\\\\\\\+ (encodeString(`toNativePath $FTM_TheMAP`)) + \\\\\\\\+ (encodeString(`toNativePath $FTM_File`)) + \ if (catchQuiet(eval($UnMAPCmd))) { $wrong = 1; FTM_Log \\(\normal texture file from \\\ FTM_Log \\\ Could be permission issue, or 'imf_copy' can not be found in system executable path, or original .map file is not a mentalray memory-mapped texture file.\ } else FTM_Log \\(\succeed. => \\\+ `toNativePath $FTM_File` + \ } if (!$wrong) { string $pathCmd = \-typ \\\\+ $FTM_FileNodes[$i] + \ if (catchQuiet(eval($pathCmd))) FTM_Log \\\Attribute \\\is locked/connected and can NOT be modified!\ else FTM_Log \\\memory-mapped texture file unset


maya贴图路径找回脚本(5).doc 将本文的Word文档下载到电脑 下载失败或者文档不完整,请联系客服人员解决!

下一篇:标准化党支部资料目录

相关阅读
本类排行
× 注册会员免费下载(下载后可以自由复制和排版)

马上注册会员

注:下载文档有可能“只有目录或者内容不全”等情况,请下载之前注意辨别,如果您已付费且无法下载或内容有问题,请联系我们协助你处理。
微信: QQ: