// =========================================================================== // Copyright 2018 Autodesk, Inc. All rights reserved. // // Use of this software is subject to the terms of the Autodesk license // agreement provided at the time of installation or download, or which // otherwise accompanies this software in either electronic or hard copy form. // =========================================================================== // // provided at the time of installation or download, or which otherwise accompanies // // Procedures specifying the UI layout for ilrBakeLayer // in Maya's Attribute Editor // global proc AEilrUpdateBakeLayerMembersList(string $layer) { string $members[] = `sets -query $layer`; textScrollList -edit -removeAll AEilrBakeLayerMembersList; for ($m in $members) { textScrollList -edit -append $m AEilrBakeLayerMembersList; } } global proc AEilrBakeLayerMembersReplace(string $attr) { string $layer; string $buffer[]; tokenize($attr, ".", $buffer); $layer = $buffer[0]; AEilrUpdateBakeLayerMembersList($layer); } global proc AEilrBakeLayerMembersNew(string $attr) { setUITemplate -pushTemplate attributeEditorTemplate; columnLayout -columnAttach "both" 5 -rowSpacing 10 -columnWidth 280; textScrollList //-numberOfRows 6 -allowMultiSelection false AEilrBakeLayerMembersList; setParent ..; setUITemplate -popTemplate; AEilrBakeLayerMembersReplace $attr; } global proc AEilrBakeLayerTemplate(string $node) { editorTemplate -beginScrollLayout; editorTemplate -beginLayout "Layer Members" -collapse false; editorTemplate -callCustom "AEilrBakeLayerMembersNew" "AEilrBakeLayerMembersReplace" "dagSetMembers"; editorTemplate -endLayout; editorTemplate -beginLayout "Layer Options" -collapse false; editorTemplate -l "Renderable" -ac "renderable"; editorTemplate -endLayout; // include/call base class/node attributes AEobjectSetNoScroll $node; // suppressed attributes editorTemplate -s "version"; editorTemplate -s "index"; editorTemplate -s "renderOptions"; editorTemplate -s "textureBakeOptions"; editorTemplate -s "vertexBakeOptions"; editorTemplate -s "surfaceTransferOptions"; editorTemplate -s "sourceLinks"; editorTemplate -s "envelopeLinks"; editorTemplate -addExtraControls; editorTemplate -endScrollLayout; }