Esempio n. 1
0
 public CSG_Tree(Mesh m)
 {
     operation = CSG_Operation.no_op;
     this.m    = m;
     left      = null;
     right     = null;
 }
Esempio n. 2
0
 public CSG_Tree(CSG_Tree lhs, CSG_Tree rhs, CSG_Operation op)
 {
     left           = lhs;
     right          = rhs;
     operation      = op;
     current_object = null;
 }
Esempio n. 3
0
        //for leaf nodes
        public CSG_Tree(GameObject obj)
        {
            operation = CSG_Operation.no_op;
            CSG_Model csg_model_a = new CSG_Model(obj);

            current_object = new CSG_Node(csg_model_a.ToPolygons());
            left           = null;
            right          = null;
        }
Esempio n. 4
0
 public void remove_references()
 {
     this.current_object = null;
     if (left != null)
     {
         left.remove_references();
         left = null;
     }
     if (right != null)
     {
         right.remove_references();
         right = null;
     }
 }