forked from izrik/FbxSharp
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathFbxCluster.cs
More file actions
174 lines (130 loc) · 3.78 KB
/
FbxCluster.cs
File metadata and controls
174 lines (130 loc) · 3.78 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
using System;
using System.Collections.Generic;
namespace FbxSharp
{
public class FbxCluster : FbxSubDeformer
{
public FbxCluster(string name="")
: base(name)
{
Link = this.SrcObjects.CreateObjectView<FbxNode>();
}
#region Public Member Functions
public void SetControlPointIWCount(int pCount)
{
throw new NotImplementedException();
}
#endregion
#region General Functions
public override EType GetSubDeformerType()
{
return EType.eCluster;
}
public void Reset()
{
throw new NotImplementedException();
}
#endregion
#region Link Mode, Link Node, Associate Model
public enum ELinkMode
{
eNormalize,
eAdditive,
eTotalOne,
}
public ELinkMode LinkMode = ELinkMode.eNormalize;
public void SetLinkMode(ELinkMode pMode)
{
LinkMode = pMode;
}
public ELinkMode GetLinkMode()
{
return LinkMode;
}
public readonly ObjectView<FbxNode> Link;
public void SetLink(FbxNode pNode)
{
if (GetLink() == pNode)
return;
if (GetLink() != null)
{
DisconnectSrcObject(GetLink());
}
ConnectSrcObject(pNode);
}
public FbxNode GetLink()
{
return Link.Get();
}
public void SetAssociateModel(FbxNode pNode)
{
throw new NotImplementedException();
}
public FbxNode GetAssociateModel()
{
throw new NotImplementedException();
}
#endregion
#region Control Points
public readonly List<int> ControlPointIndices = new List<int>();
public readonly List<double> ControlPointWeights = new List<double>();
public void AddControlPointIndex(int pIndex, double pWeight)
{
ControlPointIndices.Add(pIndex);
ControlPointWeights.Add(pWeight);
}
public int GetControlPointIndicesCount()
{
return ControlPointIndices.Count;
}
public IList<int> GetControlPointIndices()
{
return ControlPointIndices;
}
public IList<double> GetControlPointWeights()
{
return ControlPointWeights;
}
#endregion
#region Transformation matrices
public FbxMatrix Transform = FbxMatrix.Identity;
public void SetTransformMatrix(FbxMatrix pMatrix)
{
Transform = pMatrix;
}
public FbxMatrix GetTransformMatrix(FbxMatrix pMatrix)
{
return Transform;
}
public FbxMatrix TransformLink = FbxMatrix.Identity;
public void SetTransformLinkMatrix(FbxMatrix pMatrix)
{
TransformLink = pMatrix;
}
public FbxMatrix GetTransformLinkMatrix(FbxMatrix pMatrix)
{
return TransformLink;
}
public void SetTransformAssociateModelMatrix(FbxMatrix pMatrix)
{
throw new NotImplementedException();
}
public FbxMatrix GetTransformAssociateModelMatrix(FbxMatrix pMatrix)
{
throw new NotImplementedException();
}
public void SetTransformParentMatrix(FbxMatrix pMatrix)
{
throw new NotImplementedException();
}
public FbxMatrix GetTransformParentMatrix(FbxMatrix pMatrix)
{
throw new NotImplementedException();
}
public bool IsTransformParentSet()
{
throw new NotImplementedException();
}
#endregion
}
}