//AllocateHierarchy public override Frame CreateFrame(string name) { OpsFrame frame = new OpsFrame(); frame.Name = name; return(frame); }
public static void ComputeLocalToWorld(OpsFrame root, Matrix ParentWorld) { root.LocalToWorld = root.TransformationMatrix * ParentWorld; for (OpsMeshContainer mc = root.MeshContainer as OpsMeshContainer; mc != null; mc = mc.NextContainer as OpsMeshContainer) { mc.LocalToWorld = root.LocalToWorld; } for (OpsFrame f = root.FrameFirstChild as OpsFrame; f != null; f = f.FrameSibling as OpsFrame) { ComputeLocalToWorld(f, root.LocalToWorld); } }
public static void ComputeLocalToWorld( OpsFrame root, Matrix ParentWorld ) { root.LocalToWorld = root.TransformationMatrix * ParentWorld; for( OpsMeshContainer mc = root.MeshContainer as OpsMeshContainer; mc != null; mc = mc.NextContainer as OpsMeshContainer ) { mc.LocalToWorld = root.LocalToWorld; } for( OpsFrame f = root.FrameFirstChild as OpsFrame; f != null; f = f.FrameSibling as OpsFrame ) { ComputeLocalToWorld( f, root.LocalToWorld ); } }
//AllocateHierarchy public override Frame CreateFrame(string name) { OpsFrame frame= new OpsFrame(); frame.Name = name; return frame; }