ToTree() public method

public ToTree ( ) : TreeNode
return System.Windows.Forms.TreeNode
Ejemplo n.º 1
0
 public void LoadStaticMesh(int index)
 {
     stm = new StaticMesh(pcc, index);
     Preview3D.StatMesh = stm;
     //Preview3D.SkelMesh = null;
     Preview3D.CamOffset = new Vector3(0, 0, 0);
     treeView1.Nodes.Clear();
     treeView1.Nodes.Add(stm.ToTree());
     treeView1.Nodes[0].Expand();
 }
Ejemplo n.º 2
0
 public void LoadStaticMesh(int index)
 {
     stm = new StaticMesh(pcc as ME3Package, index);
     List<MaterialInstanceConstant> matInsts = stm.Mesh.Mat.MatInst;
     bool foundTex = false;
     try
     {
         for (int i = 0; i < matInsts.Count; i++)
         {
             for (int j = 0; j < matInsts[i].Textures.Count; j++)
             {
                 if (matInsts[i].Textures[j].Desc.Contains("Diffuse"))
                 {
                     Preview3D.setTex(matInsts[i].Textures[j].Texture);
                     foundTex = true;
                     break;
                 }
             }
         }
     }
     catch
     {
     }
     if (!foundTex)
     {
         Preview3D.setTex();
     }
     Preview3D.StatMesh = stm;
     //Preview3D.SkelMesh = null;
     Preview3D.CamOffset = new Vector3(0, 0, 0);
     treeView1.BeginUpdate();
     treeView1.Nodes.Clear();
     treeView1.Nodes.Add(stm.ToTree());
     treeView1.Nodes[0].Expand();
     treeView1.EndUpdate();
 }