// create BBTree structure
// - get bounding boxes
- std::vector<double> bboxes(6*numSrcElems);
+ std::vector<double> bboxes(2*SPACEDIM*numSrcElems);
int* srcElemIdx = new int[numSrcElems];
for(unsigned long i = 0; i < numSrcElems ; ++i)
{
// get source bboxes in right order
- const BoundingBox* box = srcElems[i]->getBoundingBox();
- bboxes[6*i+0] = box->getCoordinate(BoundingBox::XMIN);
- bboxes[6*i+1] = box->getCoordinate(BoundingBox::XMAX);
- bboxes[6*i+2] = box->getCoordinate(BoundingBox::YMIN);
- bboxes[6*i+3] = box->getCoordinate(BoundingBox::YMAX);
- bboxes[6*i+4] = box->getCoordinate(BoundingBox::ZMIN);
- bboxes[6*i+5] = box->getCoordinate(BoundingBox::ZMAX);
-
+ srcElems[i]->getBoundingBox()->toCompactData(bboxes.data()+6*i);
srcElemIdx[i] = srcElems[i]->getIndex();
}
// - calculate intersection by calling intersectCells
for(unsigned long i = 0; i < numTargetElems; ++i)
{
-
-
-
std::vector<ConnType> intersectElems;
//tree.getElementsAroundPoint(targetBox, intersectElems);