Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/tesselationhelpers.cpp

    rb998c3 rfc9992  
    143143  if (fabs(HalfplaneIndicator) < MYEPSILON)
    144144    {
    145       if ((TempNormal.ScalarProduct(AlternativeDirection) <0 and AlternativeIndicator >0) or (TempNormal.ScalarProduct(AlternativeDirection) >0 and AlternativeIndicator <0))
     145      if ((TempNormal.ScalarProduct(AlternativeDirection) <0 && AlternativeIndicator >0) || (TempNormal.ScalarProduct(AlternativeDirection) >0 && AlternativeIndicator <0))
    146146        {
    147147          TempNormal.Scale(-1);
     
    150150  else
    151151    {
    152       if (TempNormal.ScalarProduct(Direction)<0 && HalfplaneIndicator >0 || TempNormal.ScalarProduct(Direction)>0 && HalfplaneIndicator<0)
     152      if (((TempNormal.ScalarProduct(Direction)<0) && (HalfplaneIndicator >0)) || ((TempNormal.ScalarProduct(Direction)>0) && (HalfplaneIndicator<0)))
    153153        {
    154154          TempNormal.Scale(-1);
     
    558558 * @return point which is second closest to the provided one
    559559 */
    560 TesselPoint* FindSecondClosestPoint(const Vector* Point, const LinkedCell* const LC)
     560TesselPoint* FindSecondClosestTesselPoint(const Vector* Point, const LinkedCell* const LC)
    561561{
    562562        Info FunctionInfo(__func__);
     
    613613 * @return point which is closest to the provided one, NULL if none found
    614614 */
    615 TesselPoint* FindClosestPoint(const Vector* Point, TesselPoint *&SecondPoint, const LinkedCell* const LC)
     615TesselPoint* FindClosestTesselPoint(const Vector* Point, TesselPoint *&SecondPoint, const LinkedCell* const LC)
    616616{
    617617        Info FunctionInfo(__func__);
     
    639639            helper.CopyVector(Point);
    640640            helper.SubtractVector((*Runner)->node);
    641             double currentNorm = helper. Norm();
     641            double currentNorm = helper.NormSquared();
    642642            if (currentNorm < distance) {
    643643              secondDistance = distance;
     
    866866    }
    867867    *tecplot << "\", N=" << TesselStruct->PointsOnBoundary.size() << ", E=" << TesselStruct->TrianglesOnBoundary.size() << ", DATAPACKING=POINT, ZONETYPE=FETRIANGLE" << endl;
    868     int i=0;
    869     for (cloud->GoToFirst(); !cloud->IsEnd(); cloud->GoToNext(), i++);
     868    int i=cloud->GetMaxId();
    870869    int *LookupList = new int[i];
    871870    for (cloud->GoToFirst(), i=0; !cloud->IsEnd(); cloud->GoToNext(), i++)
Note: See TracChangeset for help on using the changeset viewer.