[MOAB-dev] r3240 - MOAB/trunk
bmsmith6 at wisc.edu
bmsmith6 at wisc.edu
Thu Oct 22 11:51:07 CDT 2009
Author: bmsmith
Date: 2009-10-22 11:51:06 -0500 (Thu, 22 Oct 2009)
New Revision: 3240
Modified:
MOAB/trunk/AEntityFactory.cpp
MOAB/trunk/MBAdaptiveKDTree.cpp
MOAB/trunk/ReadCGM.cpp
Log:
-Fix a bug in which a skin vert is inserted into a curve in t_joint. Tris adjacent
to the edge that will be t-jointed should also be t-jointed, unless they are in
the surface being zipped. This is because we know the inserted vert is already part
of the tri.
Modified: MOAB/trunk/AEntityFactory.cpp
===================================================================
--- MOAB/trunk/AEntityFactory.cpp 2009-10-22 03:58:24 UTC (rev 3239)
+++ MOAB/trunk/AEntityFactory.cpp 2009-10-22 16:51:06 UTC (rev 3240)
@@ -31,6 +31,8 @@
#include <algorithm>
#include <set>
+#include <iostream> // brandon
+
MBErrorCode AEntityFactory::get_vertices( MBEntityHandle h,
const MBEntityHandle*& vect_out,
int& count_out,
@@ -584,6 +586,7 @@
bool create_if_missing,
std::vector<MBEntityHandle> &adjacent_entities)
{
+ //std::cout << "mVertElemAdj=" << mVertElemAdj << std::endl;
MBEntityType ent_type = TYPE_FROM_HANDLE(entity);
if (ent_type == MBMAXTYPE) return MB_TYPE_OUT_OF_RANGE;
Modified: MOAB/trunk/MBAdaptiveKDTree.cpp
===================================================================
--- MOAB/trunk/MBAdaptiveKDTree.cpp 2009-10-22 03:58:24 UTC (rev 3239)
+++ MOAB/trunk/MBAdaptiveKDTree.cpp 2009-10-22 16:51:06 UTC (rev 3240)
@@ -1491,9 +1491,11 @@
return rval;
// test that point is inside tree
- if (point[0] < result.box_min()[0] || point[0] > result.box_max()[0] ||
- point[1] < result.box_min()[1] || point[1] > result.box_max()[1] ||
- point[2] < result.box_min()[2] || point[2] > result.box_max()[2])
+ // Brandon: add a tolerance
+ double tol = 0.001;
+ if (point[0] < result.box_min()[0]-tol || point[0] > result.box_max()[0]+tol ||
+ point[1] < result.box_min()[1]-tol || point[1] > result.box_max()[1]+tol ||
+ point[2] < result.box_min()[2]-tol || point[2] > result.box_max()[2]+tol)
return MB_ENTITY_NOT_FOUND;
// initialize iterator at tree root
Modified: MOAB/trunk/ReadCGM.cpp
===================================================================
--- MOAB/trunk/ReadCGM.cpp 2009-10-22 03:58:24 UTC (rev 3239)
+++ MOAB/trunk/ReadCGM.cpp 2009-10-22 16:51:06 UTC (rev 3240)
@@ -191,7 +191,8 @@
for (int i = entlist.size(); i--; ) {
RefEntity* ent = entlist.get_and_step();
MBEntityHandle handle;
- rval = mdbImpl->create_meshset( dim == 1 ? MESHSET_ORDERED : MESHSET_SET, handle );
+ rval = mdbImpl->create_meshset( dim == 1 ? MESHSET_ORDERED | MESHSET_TRACK_OWNER :
+ MESHSET_SET | MESHSET_TRACK_OWNER, handle );
if (MB_SUCCESS != rval)
return rval;
More information about the moab-dev
mailing list