コード例 #1
0
 public void GetCurrentPositions_SingleVectorBarycentric(Vector3d[] NewPositions)
 {
     gParallel.ForEach <int>(DisplaceMesh.VertexIndices(), (vid) => {
         Frame3f triFrame = BaseMesh.GetTriFrame(BaryFaceDisplacements[vid].tID);
         Vector3f offsetV = triFrame.FromFrameV(BaryFaceDisplacements[vid].dv);
         Vector3d triPt   = BaseMesh.GetTriBaryPoint(BaryFaceDisplacements[vid].tID,
                                                     BaryFaceDisplacements[vid].a, BaryFaceDisplacements[vid].b, BaryFaceDisplacements[vid].c);
         NewPositions[vid] = triPt + offsetV;
         //NewPositions[vid] = triPt;
     });
 }