Go to: Related nodes.

fosterParents are transform nodes that are used to handle parent-in edits. A parent-in edit is one in which a main-scene node is the child of a referenced node or a node in an assembly. So the hierarchy is as follows:

nodeInReferenceOrAssembly |_ mainSceneNode

When the reference/assembly containing the parent node is unloaded, we need to parent mainSceneNode under a place-holder node, which is the fosterParent node.

The fosterParent is needed for 2 reasons: 1) To ensure dag name uniqueness is preserved. If we had another node named 'mainSceneNode' (parented under world, for example), removing the parent node (nodeInReferenceOrAssembly) would cause a name-clash with |mainSceneNode. 2) To ensure position of child doesn't change. The fosterParent node will be populated with the TRSV position of nodeInReferenceOrAssembly. This way, regardless of whether the parent node is currently in the scene or not, the position of the child will not change.

So when we unload the parent node, we will re-parent the child node as follows:

fosterParent1 |_ mainSceneNode

And the parent edit will use "fosterParent1|mainSceneNode" as the child node name.

The fosterParent node will be written to file. But it will be deleted after the parent edit is successfully applied. So when all references or assemblies are fully loaded, the only fosterParents in the scene will be those for failed parent edits.

If a parent edit fails, we'll leave the fosterParent in the scene. This way, if the failing edit is corrected at some other time, it can be properly recovered.

IMPORTANT NOTE: fosterParents saved out in pre-2014 files will still be plain Ttransform's and not TfosterParent's. So the only way to identify that it is indeed a fosterParent is to see if its message attribute is connected to a reference node's fosterParent/fosterSibling attribute.

All fosterParents created/saved after Maya 2014 will be TfosterParent nodes, and a simple ->isA(TfosterParent) is enough to identify it.

Node nameParentsClassificationMFn typeCompatible function sets

Related nodes

transform, assembly, reference