예제 #1
0
        private void Initialize()
        {
            ptInput = connectedMenus.ptInput;
            connectedMenus.ptInput.Initialize(this);
            connectedMenus.ptOutputMenu.Initialize(this);
            List <string> neg1 = new List <string>()
            {
                "-", "1"
            };
            List <string> pos1 = new List <string>()
            {
                "1"
            };

            ptSet = new PtSet();

            eqnSet = new EqnSet();

            ptInput.ChangeOutput(ptSet.ptCoords["pt1"].X);
            updatePoint("pt1", new Vector3(1, 2, 3), false);


            updatePoint("pt2", new Vector3(2, 4, 6), false);

            updatePoint("pt3", new Vector3(0, 0, 1), false);
        }
예제 #2
0
        private void Initialize()
        {
            ptInput = connectedMenus.ptInput;
            connectedMenus.ptInput.Initialize(this);
            connectedMenus.ptOutputMenu.Initialize(this);
            List <string> neg1 = new List <string>()
            {
                "-", "1"
            };
            List <string> pos1 = new List <string>()
            {
                "1"
            };

            ptSet = new PtSet();

            eqnSet = new EqnSet();

            ptInput.ChangeOutput(ptSet.ptCoords["pt1"].X);
            //in unity z is the right 3rd axis
            updatePoint("pt1", new Vector3(1, 2, 3), false); // vector
            updatePoint("pt2", new Vector3(0, 1, 0), false); // first axis
            updatePoint("pt3", new Vector3(1, 0, 0), false); // origin
            ptInput.setPlane();
        }
예제 #3
0
        private void Initialize()
        {
            ptInput = connectedMenus.ptInput;
            connectedMenus.ptInput.Initialize(this);
            connectedMenus.ptOutputMenu.Initialize(this);
            List <string> neg1 = new List <string>()
            {
                "-", "1"
            };
            List <string> pos1 = new List <string>()
            {
                "1"
            };

            ptSet = new PtSet();

            eqnSet = new EqnSet();

            ptInput.ChangeOutput(ptSet.ptCoords["pt1"].X);
            updatePoint("pt1", new Vector3(-2, 3, 4), false);
            updatePoint("pt2", new Vector3(1, 1, 0), false);
            updatePoint("pt3", new Vector3(1, 90, -1), false);
            //updatePoint("pt1", new Vector3(-1, 1, 1), false);  //Old default
            //updatePoint("pt2", new Vector3(1, -1, 1), false);  //Old default
            //updatePoint("pt3", new Vector3(1, 0, -1), false);  //Old default
        }
예제 #4
0
 void Update()
 {
     if (!ptSetExist && ptManager != null && ptManager.eqnSet != null)
     {
         ptSetExist = true;
         eqnSet     = ptManager.eqnSet;
     }
 }
예제 #5
0
 void Awake()
 {
     if (ptManager != null && ptManager.eqnSet != null)
     {
         ptSetExist = true;
         eqnSet     = ptManager.eqnSet;
     }
 }
예제 #6
0
    public EqnSet ShallowCopy()
    {
        EqnSet newEs = new EqnSet();

        newEs.eqnCoefs     = new Dictionary <string, EqnCoef>((Dictionary <string, EqnCoef>)eqnCoefs);
        newEs.coefValidity = coefValidity;

        return(newEs);
    }
예제 #7
0
    public EqnSet DeepCopy()
    {
        EqnSet newEs = new EqnSet();

        newEs.eqnCoefs = new Dictionary <string, EqnCoef>();
        foreach (string key in eqnCoefs.Keys)
        {
            newEs.eqnCoefs.Add(key, new EqnCoef(eqnCoefs[key]));
        }

        newEs.coefValidity = coefValidity;

        return(newEs);
    }
예제 #8
0
        private void Initialize()
        {
            ptInput2D = connectedMenus.ptInput2D;
            connectedMenus.ptInput2D.Initialize(this);      //tmp
            connectedMenus.ptOutputMenu2D.Initialize(this); //tmp
            ptSet = new PtSet();

            eqnSet = new EqnSet();

            ptInput2D.ChangeOutput(ptSet.ptCoords["pt1"].X);
            updatePoint("pt1", new Vector3(0, 1, 0), false);
            updatePoint("pt2", new Vector3(1, 0, 0), false);
            updatePoint("pt3", new Vector3(0, 0, 0), false); //this line can probably be removed
        }
예제 #9
0
        private void Initialize()
        {
            ptInput = connectedMenus.ptInput;
            connectedMenus.ptInput.Initialize(this);
            connectedMenus.ptOutputMenu.Initialize(this);

            ptSet = new PtSet();

            eqnSet = new EqnSet();

            ptInput.ChangeOutput(ptSet.ptCoords["pt1"].X);
            updatePoint("pt1", new Vector3(0, 1, 0), false);
            updatePoint("pt2", new Vector3(1, 0, 0), false);
            updatePoint("pt3", new Vector3(0, 0, 1), false);
        }