double xBaryBB, yBaryBB;
double fact=normalizeExt(&other, xBaryBB, yBaryBB);
//Locate 'this' relative to 'other'
- other.performLocatingOperation(*this);
+ other.performLocatingOperationSlow(*this);
std::vector<QuadraticPolygon *> res=buildIntersectionPolygons(other,*this);
for(std::vector<QuadraticPolygon *>::iterator it=res.begin();it!=res.end();it++)
{
}
}
+void QuadraticPolygon::performLocatingOperationSlow(QuadraticPolygon& pol2) const
+{
+ IteratorOnComposedEdge it(&pol2);
+ for(it.first();!it.finished();it.next())
+ {
+ ElementaryEdge *cur=it.current();
+ cur->locateFullyMySelfAbsolute(*this);
+ }
+}
+
/*!
* Given 2 polygons 'pol1' and 'pol2' (localized) the resulting polygons are returned.
*
void intersectForPoint(const QuadraticPolygon& other, std::vector< int >& numberOfCreatedPointsPerEdge) const;
public://Only public for tests reasons
void performLocatingOperation(QuadraticPolygon& pol2) const;
+ void performLocatingOperationSlow(QuadraticPolygon& pol2) const;
static void SplitPolygonsEachOther(QuadraticPolygon& pol1, QuadraticPolygon& pol2, int& nbOfSplits);
std::vector<QuadraticPolygon *> buildIntersectionPolygons(const QuadraticPolygon& pol1, const QuadraticPolygon& pol2) const;
bool amIAChanceToBeCompletedBy(const QuadraticPolygon& pol1Splitted, const QuadraticPolygon& pol2NotSplitted, bool& direction);