Revision: 73864
          http://sourceforge.net/p/brlcad/code/73864
Author:   starseeker
Date:     2019-09-09 20:56:29 +0000 (Mon, 09 Sep 2019)
Log Message:
-----------
Making a bbox with two points doesn't do what I expected in some cases.  NIST2 
face 5 new converges, on to face 37...

Modified Paths:
--------------
    brlcad/trunk/src/libbrep/cdt_edge.cpp

Modified: brlcad/trunk/src/libbrep/cdt_edge.cpp
===================================================================
--- brlcad/trunk/src/libbrep/cdt_edge.cpp       2019-09-09 20:18:24 UTC (rev 
73863)
+++ brlcad/trunk/src/libbrep/cdt_edge.cpp       2019-09-09 20:56:29 UTC (rev 
73864)
@@ -1625,6 +1625,7 @@
     for (int index = 0; index < brep->m_L.Count(); index++) {
        const ON_BrepLoop &loop = brep->m_L[index];
        ON_BrepFace *face = loop.Face();
+       int face_index = face->m_face_index;
        std::set<cdt_mesh::bedge_seg_t *> ws;
 
        // Build the initial set to check (all edges associated with a loop 
trim)
@@ -1665,7 +1666,8 @@
                ON_2dPoint p2d2 = 
s_cdt->brep->m_T[tseg->trim_ind].PointAt(tseg->trim_end);
 
                // Trim 2D bbox
-               ON_BoundingBox bb(p2d1, p2d2);
+               ON_Line line(p2d1, p2d2);
+               ON_BoundingBox bb = line.BoundingBox();
                bb.m_max.x = bb.m_max.x + ON_ZERO_TOLERANCE;
                bb.m_max.y = bb.m_max.y + ON_ZERO_TOLERANCE;
                bb.m_min.x = bb.m_min.x - ON_ZERO_TOLERANCE;
@@ -1737,7 +1739,7 @@
 
            struct bu_vls fname = BU_VLS_INIT_ZERO;
            bu_vls_sprintf(&fname, "%d-rtree_2d_split_update_%d.plot3", 
face->m_face_index, split_cnt);
-           plot_rtree_2d2(s_cdt->trim_segs[face->m_face_index], 
bu_vls_cstr(&fname));
+           plot_rtree_2d2(s_cdt->trim_segs[face_index], bu_vls_cstr(&fname));
            bu_vls_free(&fname);
        }
 

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.



_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/brlcad-commits

Reply via email to