public void removeChildSolver(BEPUikSolverDefinition child)
 {
     childSolvers.Remove(child);
     if (childSolversManager != null)
     {
         childSolversManager.removeSubInterface(child);
     }
 }
 public void addChildSolver(BEPUikSolverDefinition child)
 {
     childSolvers.Add(child);
     if (childSolversManager != null)
     {
         childSolversManager.addSubInterface(child, child.getEditInterface());
     }
 }
Beispiel #3
0
        internal BEPUikSolver(BEPUikSolverDefinition definition)
        {
            this.Name = definition.Name;
            this.AutosolveOnParentUpdate          = definition.AutosolveOnParentUpdate;
            ikSolver.ActiveSet.UseAutomass        = definition.ActiveSetUseAutomass;
            ikSolver.AutoscaleControlImpulses     = definition.AutoscaleControlImpulses;
            ikSolver.AutoscaleControlMaximumForce = definition.AutoscaleControlMaximumForce;
            ikSolver.TimeStepDuration             = definition.TimeStepDuration;
            ikSolver.ControlIterationCount        = definition.ControlIterationCount;
            ikSolver.FixerIterationCount          = definition.FixerIterationCount;
            ikSolver.VelocitySubiterationCount    = definition.VelocitySubiterationCount;

            foreach (var childSolverDef in definition.ChildSolvers)
            {
                childSolvers.Add(new BEPUikSolver(childSolverDef));
            }
        }
Beispiel #4
0
 internal void fillOutDefinition(BEPUikSolverDefinition definition)
 {
     definition.ActiveSetUseAutomass         = ikSolver.ActiveSet.UseAutomass;
     definition.AutoscaleControlImpulses     = ikSolver.AutoscaleControlImpulses;
     definition.AutoscaleControlMaximumForce = ikSolver.AutoscaleControlMaximumForce;
     definition.TimeStepDuration             = ikSolver.TimeStepDuration;
     definition.ControlIterationCount        = ikSolver.ControlIterationCount;
     definition.FixerIterationCount          = ikSolver.FixerIterationCount;
     definition.VelocitySubiterationCount    = ikSolver.VelocitySubiterationCount;
     definition.Name = Name;
     definition.AutosolveOnParentUpdate = AutosolveOnParentUpdate;
     foreach (var child in childSolvers)
     {
         var childDefinition = new BEPUikSolverDefinition();
         child.fillOutDefinition(childDefinition);
         definition.addChildSolver(childDefinition);
     }
 }
 protected BEPUikSceneDefinition(LoadInfo info)
 {
     if (info.Version == 0)
     {
         rootSolver      = new BEPUikSolverDefinition();
         rootSolver.Name = "Root";
         rootSolver.ActiveSetUseAutomass         = info.GetBoolean("activeSetUseAutomass");
         rootSolver.AutoscaleControlImpulses     = info.GetBoolean("autoscaleControlImpulses");
         rootSolver.AutoscaleControlMaximumForce = info.GetFloat("autoscaleControlMaximumForce");
         rootSolver.ControlIterationCount        = info.GetInt32("controlIterationCount");
         rootSolver.FixerIterationCount          = info.GetInt32("fixerIterationCount");
         rootSolver.TimeStepDuration             = info.GetFloat("timeStepDuration");
         rootSolver.VelocitySubiterationCount    = info.GetInt32("velocitySubiterationCount");
     }
     else
     {
         rootSolver = info.GetValue <BEPUikSolverDefinition>("RootSolver");
     }
 }
 public BEPUikSceneDefinition(String name)
 {
     this.name       = name;
     rootSolver      = new BEPUikSolverDefinition();
     rootSolver.Name = "Root";
 }