Example #1
0
 private CTrisVertex BuildVertex(ModelVertex srcV)
 {
     return writer.GetVertex(
         GetVec3(srcV.Position * scale),
         GetBones(srcV.Bones),
      				GetWeights(srcV.Bones),
         GetVec3Fixed(srcV.Normal),
         GetVec2Fixed(srcV.UV0),
         CIwVec2.g_Zero,
         CIwColour.White);
 }
Example #2
0
 public bool Equals(ModelVertex other)
 {
     if (!(Position == other.Position &&
         Normal == other.Normal &&
         UV0 == other.UV0))
         return false;
     foreach (var b1 in Bones)
     {
         foreach (var b2 in other.Bones)
             if (b1.Bone == b2.Bone && b1.Weight == b2.Weight)
                 goto nextBone1;
         return false;
         nextBone1:;
     }
     foreach (var b2 in other.Bones)
     {
         foreach (var b1 in Bones)
             if (b1.Bone == b2.Bone && b1.Weight == b2.Weight)
                 goto nextBone2;
         return false;
     nextBone2: ;
     }
     return true;
 }