// =========================================================================== // 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. // =========================================================================== // // // Creation Date: March 23, 1999 // // Procedure Name: // AEsubdivTemplate // // Description: // Creates the attribute editor controls for the subdiv node // // Input Value: // nodeName // // Output Value: // None // global proc AEsubdiv_formatCallback( string $nodeName ) // // Description: // Proc called when ($nodeName.format) attribute is // changed. We want to dim out the Depth control when // "format" is set to "Adaptive." { int $dimDepth = false; if( `getAttr ( $nodeName + ".format" )` == 1 ) { $dimDepth = true; } editorTemplate -dimControl $nodeName "depth" $dimDepth; } global proc AEsubdivTemplate( string $nodeName ) { editorTemplate -beginScrollLayout; editorTemplate -beginLayout (uiRes("m_AEsubdivTemplate.kSubdivComponentDisplay")) -collapse true; editorTemplate -label (uiRes("m_AEsubdivTemplate.kVertices")) -addControl "dispVertices"; editorTemplate -label (uiRes("m_AEsubdivTemplate.kEdges")) -addControl "dispEdges"; editorTemplate -label (uiRes("m_AEsubdivTemplate.kFaces")) -addControl "dispFaces"; editorTemplate -label (uiRes("m_AEsubdivTemplate.kUVs")) -addControl "dispMaps"; editorTemplate -label (uiRes("m_AEsubdivTemplate.kUVBorders")) -addControl "dispUVBorder"; editorTemplate -label (uiRes("m_AEsubdivTemplate.kGeometry")) -addControl "dispGeometry"; editorTemplate -label (uiRes("m_AEsubdivTemplate.kLevel")) -addControl "displayLevel"; editorTemplate -label (uiRes("m_AEsubdivTemplate.kFilter")) -addControl "displayFilter"; editorTemplate -endLayout; editorTemplate -beginLayout (uiRes("m_AEsubdivTemplate.kSubdivSurfaceDisplay")) -collapse true; editorTemplate -label (uiRes("m_AEsubdivTemplate.kResolution")) -addControl "dispResolution"; editorTemplate -label (uiRes("m_AEsubdivTemplate.kNormalsScale")) -addControl "normalsDisplayScale"; editorTemplate -endLayout; editorTemplate -beginLayout (uiRes("m_AEsubdivTemplate.kHierarchicalEditBehavior")) -collapse true; editorTemplate -addControl "scalingHierarchy"; editorTemplate -endLayout; editorTemplate -beginLayout (uiRes("m_AEsubdivTemplate.kTessellation")); editorTemplate -addControl "format" AEsubdiv_formatCallback; editorTemplate -addControl "depth"; editorTemplate -addControl "sampleCount"; editorTemplate -endLayout; // include/call base class/node attributes AEsurfaceShapeTemplate $nodeName; //suppressed attributes editorTemplate -suppress "create"; editorTemplate -suppress "cached"; editorTemplate -suppress "outSubdiv"; editorTemplate -suppress "worldSubdiv"; editorTemplate -suppress "vertex"; editorTemplate -suppress "singleVertex"; editorTemplate -suppress "singleVertexX"; editorTemplate -suppress "singleVertexY"; editorTemplate -suppress "singleVertexZ"; editorTemplate -suppress "edgeCrease"; editorTemplate -suppress "textureCoord"; editorTemplate -suppress "baseFaceCount"; editorTemplate -suppress "levelOneFaceCount"; editorTemplate -suppress "dispVerticesAsLimitPoints"; editorTemplate -suppress "localizeLimitPointsEdit"; editorTemplate -suppress "dispCreases"; editorTemplate -suppress "vertexTweak"; editorTemplate -suppress "collisionOffsetVelocityIncrement"; editorTemplate -suppress "collisionDepthVelocityIncrement"; editorTemplate -addExtraControls; editorTemplate -addDynamicControl "collisionEnable"; editorTemplate -addDynamicControl "collisionOffset"; editorTemplate -addDynamicControl "collisionDepth"; editorTemplate -addDynamicControl "collisionPriority"; editorTemplate -addDynamicControl "depthMapEnable"; editorTemplate -addDynamicControl "depthMapWeight"; editorTemplate -addDynamicControl "displayCollision"; AEaddDynRampClothCollision "collisionOffsetVelocityMultiplier"; AEaddDynRampClothCollision "collisionDepthVelocityMultiplier"; editorTemplate -endScrollLayout; }