From ed9e36f686f6576da6e11cb2aaa9f05ad672c3c8 Mon Sep 17 00:00:00 2001 From: Nikos Kastellanos Date: Tue, 24 Dec 2024 01:52:28 +0200 Subject: [PATCH] rename ancestorNode --- .../OpenAssetImporter.cs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/Xna.Framework.Content.Pipeline.Graphics/OpenAssetImporter.cs b/src/Xna.Framework.Content.Pipeline.Graphics/OpenAssetImporter.cs index 360f0eca342..078f2cfb57f 100644 --- a/src/Xna.Framework.Content.Pipeline.Graphics/OpenAssetImporter.cs +++ b/src/Xna.Framework.Content.Pipeline.Graphics/OpenAssetImporter.cs @@ -954,26 +954,26 @@ private static void GetSubtree(Node aiNode, List list) /// Gets the transform of node relative to a specific ancestor node. /// /// The node. - /// The ancestor node. Can be . + /// The ancestor node. Can be . /// - /// The relative transform. If is the + /// The relative transform. If is the /// absolute transform of is returned. /// - private static Matrix4x4 GetRelativeTransform(Node node, Node ancestor) + private static Matrix4x4 GetRelativeTransform(Node node, Node ancestorNode) { Debug.Assert(node != null); // Get transform of node relative to ancestor. Matrix4x4 transform = node.Transform; Node parent = node.Parent; - while (parent != null && parent != ancestor) + while (parent != null && parent != ancestorNode) { transform = transform * parent.Transform; parent = parent.Parent; } - if (parent == null && ancestor != null) - throw new ArgumentException(String.Format("Node \"{0}\" is not an ancestor of \"{1}\".", ancestor.Name, node.Name)); + if (parent == null && ancestorNode != null) + throw new ArgumentException(String.Format("Node \"{0}\" is not an ancestor of \"{1}\".", ancestorNode.Name, node.Name)); return transform; }