Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/triangleintersectionlist.cpp

    rbf3817 r952f38  
    99 */
    1010
    11 // include config.h
    12 #ifdef HAVE_CONFIG_H
    13 #include <config.h>
    14 #endif
    15 
    1611#include "Helpers/MemDebug.hpp"
    1712
     
    2116
    2217#include "Helpers/Info.hpp"
    23 #include "BoundaryMaps.hpp"
    24 #include "BoundaryPointSet.hpp"
    25 #include "BoundaryLineSet.hpp"
    26 #include "BoundaryTriangleSet.hpp"
    2718#include "tesselation.hpp"
    2819#include "LinearAlgebra/Vector.hpp"
     
    3223 *
    3324 */
    34 TriangleIntersectionList::TriangleIntersectionList(const Vector &x, const Tesselation *surface, const LinkedCell* LC) :
     25TriangleIntersectionList::TriangleIntersectionList(const Vector *x, const Tesselation *surface, const LinkedCell* LC) :
    3526  Point(x),
    3627  Tess(surface),
     
    7970  }
    8071  // return reference, if none can be found
    81   return Point;
     72  return *Point;
    8273};
    8374
     
    10899  if (runner != IntersectionList.end()) {
    109100    // if we have found one, check Scalarproduct between the vector
    110     Vector TestVector = (Point) - (*(*runner).second);
     101    Vector TestVector = (*Point) - (*(*runner).second);
    111102    if (fabs(TestVector.NormSquared()) < MYEPSILON) //
    112103      return true;
     
    147138    // get intersection with triangle plane
    148139    Intersection = new Vector;
    149     (*TriangleRunner)->GetClosestPointInsideTriangle(Point, *Intersection);
    150     //Log() << Verbose(1) << "Intersection between " << Point << " and " << **TriangleRunner << " is at " << *Intersection << "." << endl;
     140    (*TriangleRunner)->GetClosestPointInsideTriangle(Point, Intersection);
     141    //Log() << Verbose(1) << "Intersection between " << *Point << " and " << **TriangleRunner << " is at " << *Intersection << "." << endl;
    151142    IntersectionList.insert( pair<BoundaryTriangleSet *, Vector * > (*TriangleRunner, Intersection) );
    152143  }
     
    160151  if (DistanceList.empty())
    161152    for (TriangleVectorMap::const_iterator runner = IntersectionList.begin(); runner != IntersectionList.end(); runner++)
    162       DistanceList.insert( pair<double, BoundaryTriangleSet *> (Point.distance(*(*runner).second), (*runner).first) );
     153      DistanceList.insert( pair<double, BoundaryTriangleSet *> (Point->distance(*(*runner).second), (*runner).first) );
    163154
    164155  //for (DistanceTriangleMap::const_iterator runner = DistanceList.begin(); runner != DistanceList.end(); runner++)
Note: See TracChangeset for help on using the changeset viewer.