Пример #1
0
 public void InitializeSceneView()
 {
     SceneRootNode = SakuraCore.GetSceneNode(IntPtr.Zero);
     ActiveNode = SakuraCore.GetSceneNode(IntPtr.Zero);
     SakuraCore.GetObjectProperties(SceneRootNode);
     List<SceneNodeProp> itemList = new List<SceneNodeProp>();
     RootProp = new SceneNodeProp(SceneRootNode);
     itemList.Add(RootProp);
     SceneViewTree.ItemsSource = itemList;
 }
Пример #2
0
 public SceneNodeProp(IntPtr node)
 {
     SceneNode = node;
     DisplayName = SakuraCore.GetStringProp(SceneNode, "Name");
     Children = new List<SceneNodeProp>();
     if (node != null)
     {
        for(uint i = 0; i < SakuraCore.GetChildrenNum(SceneNode); i++)
        {
             IntPtr cd = SakuraCore.GetSceneNode(SceneNode, i);
             var childNode = new SceneNodeProp(cd);
             Children.Add(childNode);
        }
     }
 }