// =========================================================================== // 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: Mar 24, 2009 // // Procedure Name: // AEcolorProfileRelated // // Description Name; // Return all of the nodes related to the given color profile global proc string[] AEcolorProfileRelated( string $node ) { string $relatedNodes[]; int $maxConnections = 10; // do not show more than this many tabs in the AE string $connections[] = `listConnections $node`; int $loopMax = 0; if (size($connections) > $maxConnections){ $loopMax = $maxConnections; warning (uiRes("m_AEcolorProfileRelated.kTooManyNodesLabel")); } else{ $loopMax = size($connections); } int $cur; for ($cur = 0; $cur < $loopMax; $cur++){ string $objectType = `nodeType -api $connections[$cur]`; if (($objectType != "kRenderPass") && ($objectType != "kFileTexture") && ($objectType != "kMentalRayTexture") && ($objectType != "kPluginDependNode")) continue; // add the node to the list of related nodes $relatedNodes[size($relatedNodes)] = $connections[$cur]; } $relatedNodes[size($relatedNodes)] = $node; return $relatedNodes; }