private void SetInfluences(params InfluenceDef[] influences) { Remapper remap = new Remapper(); remap.Remap(influences); for (int i = 0; i < remap.RemapTable.Length; ++i) { _facePoints[i].InfluenceIndex = remap.RemapTable[i]; } _influences = new InfluenceDef[remap.ImplementationLength]; for (int i = 0; i < remap.ImplementationLength; ++i) { _influences[i] = influences[remap.ImplementationTable[i]]; } HashSet <string> utilized = new HashSet <string>(); foreach (InfluenceDef inf in _influences) { if (inf != null) { for (int i = 0; i < inf.WeightCount; ++i) { utilized.Add(inf.Weights[i].Bone); } } } _utilizedBones = utilized.ToArray(); }
public override bool Equals(object obj) { InfluenceDef other = obj as InfluenceDef; if (other == null || WeightCount == other.WeightCount) { return(false); } for (int i = 0; i < WeightCount; ++i) { if (Weights[i] != other.Weights[i]) { return(false); } } return(true); }
public Vertex(Vec3 position, InfluenceDef inf, Vec2 texCoord) : this(position, inf) { TexCoord = texCoord; }
public Vertex(Vec3 position, InfluenceDef inf, Vec3 normal, Vec3 binormal, Vec3 tangent, Vec2 texCoord, ColorF4 color) : this(position, inf, normal, texCoord, color) { Binormal = binormal; Tangent = tangent; }
public Vertex(Vec3 position, InfluenceDef inf, Vec3 normal, Vec2 texCoord, ColorF4 color) : this(position, inf, normal, texCoord) { Color = color; }
public Vertex(Vec3 position, InfluenceDef inf, Vec3 normal) : this(position, inf) { Normal = normal; }
public Vertex(Vec3 position, InfluenceDef inf) : this(position) { Influence = inf; }
public Vertex(InfluenceDef inf) { Influence = inf; }