Ignore:
Timestamp:
Aug 20, 2014, 1:06:16 PM (11 years ago)
Author:
Frederik Heber <heber@…>
Children:
ce0ca4
Parents:
c1413b
git-author:
Frederik Heber <heber@…> (07/18/14 16:06:44)
git-committer:
Frederik Heber <heber@…> (08/20/14 13:06:16)
Message:

findBestMatching() now returns the MCS instead of the joined Points.

  • this is preparatory to obtain an association and not join points.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Fragmentation/Exporters/SphericalPointDistribution.cpp

    rc1413b rc8d2e7  
    578578 * \param _polygon here, we have indices 0,1,2,...
    579579 * \param _newpolygon and here we need to find the correct indices
    580  * \return list of indices: first in \a _polygon goes to first index for \a _newpolygon
     580 * \return control structure containing the matching and more
    581581 */
    582 SphericalPointDistribution::IndexList_t SphericalPointDistribution::findBestMatching(
     582SphericalPointDistribution::MatchingControlStructure
     583SphericalPointDistribution::findBestMatching(
    583584    const WeightedPolygon_t &_polygon
    584585    )
     
    622623  }
    623624
    624   // combine multiple points and create simple IndexList from IndexTupleList
    625   const SphericalPointDistribution::IndexList_t IndexList =
    626       joinPoints(points, MCS.newpoints, MCS.bestmatching);
    627 
    628   return IndexList;
     625  return MCS;
    629626}
    630627
     
    893890
    894891  if (_N > 0) {
    895     IndexList_t bestmatching = findBestMatching(_polygon);
     892    // combine multiple points and create simple IndexList from IndexTupleList
     893    MatchingControlStructure MCS = findBestMatching(_polygon);
     894    IndexList_t bestmatching = joinPoints(points, MCS.newpoints, MCS.bestmatching);
    896895    LOG(2, "INFO: Best matching is " << bestmatching);
    897896
Note: See TracChangeset for help on using the changeset viewer.