public FBXBindingManager(FBXDocument doc) { this.doc = doc; this.objects = doc.GetDeclaration <FBXObject>(FBXDocument.Objects); this.connectionObject = doc.GetObject("Connections"); this.connections = connectionObject.Declarations["Connect"]; LoadConnectionHeirarchys(); }
public FBXObject GetObjectById(string id, string type = null) { if (type == null) { foreach (var l in declarations.Values) { for (int i = 0; i < l.Count; i++) { FBXObject obj = l[i] as FBXObject; if (obj != null && obj.Id == id) { return(obj); } } } } else { List <FBXDeclarationNode> list; if (!declarations.TryGetValue(type, out list)) { return(null); } if (list != null) { for (int i = 0; i < list.Count; i++) { FBXObject obj = list[i] as FBXObject; if (obj != null && obj.Id == id) { return(obj); } } } } return(null); }
public FBXListProperty GetProperty(string name) { FBXObject propertys = (FBXObject)declarations["Properties60"][0]; return((FBXListProperty)propertys.declarations["Property"].Find(x => ((FBXListProperty)x).Values[0] == name)); }