Revision: 64364
http://sourceforge.net/p/brlcad/code/64364
Author: starseeker
Date: 2015-03-11 01:29:53 +0000 (Wed, 11 Mar 2015)
Log Message:
-----------
Remove some debugging printouts
Modified Paths:
--------------
brlcad/trunk/src/libbrep/shape_recognition.cpp
brlcad/trunk/src/libbrep/shape_recognition_planar.cpp
Modified: brlcad/trunk/src/libbrep/shape_recognition.cpp
===================================================================
--- brlcad/trunk/src/libbrep/shape_recognition.cpp 2015-03-11 01:01:41 UTC
(rev 64363)
+++ brlcad/trunk/src/libbrep/shape_recognition.cpp 2015-03-11 01:29:53 UTC
(rev 64364)
@@ -43,9 +43,6 @@
* subset has not already been seen, add it to the brep's set of
* subbreps */
for (int i = 0; i < brep->m_F.Count(); i++) {
- if (i >= 26 && i <= 30) {
- std::cout << "Considering face " << i << "\n";
- }
std::string key;
std::set<int> faces;
std::set<int> loops;
@@ -93,9 +90,6 @@
}
}
key = face_set_key(faces);
- if (i >= 26 && i <= 30) {
- std::cout << "key built: " << key << "\n";
- }
/* If we haven't seen this particular subset before, add it */
if (subbrep_keys.find(key) == subbrep_keys.end()) {
@@ -131,7 +125,6 @@
new_obj->params->bool_op = 'u';
}
- (void)subbrep_make_brep(new_obj);
surface_t hof = highest_order_face(new_obj);
if (hof >= SURFACE_GENERAL) {
new_obj->type = BREP;
@@ -171,10 +164,8 @@
ret = ps->equal_range(bu_vls_addr(obj->key));
for (std::multimap<const char *, long *>::iterator it = ret.first; it !=
ret.second; it++) {
const struct subbrep_object_data *sub_obj = (const struct
subbrep_object_data *)it->second;
- bu_log(" sub_obj: %s\n", bu_vls_addr(sub_obj->key));
if (sub_obj) {
bu_ptbl_ins(subbreps_tree, (long *)sub_obj);
- std::cout << "array len: " << BU_PTBL_LEN(subbreps_tree) << "\n";
subbrep_assemble_boolean_tree(ps, subbreps_tree, sub_obj);
}
}
@@ -193,6 +184,17 @@
std::multimap<const char *, long *> ps;
for (unsigned int i = 0; i < BU_PTBL_LEN(subbreps); i++) {
struct subbrep_object_data *obj = (struct subbrep_object_data
*)BU_PTBL_GET(subbreps, i);
+ // If we can find a top union, things are easier. Can we rely on this
100%? Need to
+ // think about it - maybe yes... if so, all subbreps can be
categorized. Subbreps that
+ // share a face with the toplevel union can be characterized, and if
any of those immediate
+ // mating subbreps have their own subbreps its a trigger to form a
comb. Any subbrep that
+ // shares a face with the comb will have to subtract the whole comb,
unless we do some sort
+ // of bounding box based subset identification... Probably necessary
to keep the booleans
+ // reasonable. nist 2 is a good test case for this...
+ if (obj->fil_cnt == 0) {
+ std::cout << "Top union found: " << bu_vls_addr(obj->key) << "\n";
+ }
+
if (obj->params->bool_op == '-') {
int found_parent = 0;
for (unsigned int j = 0; j < BU_PTBL_LEN(subbreps); j++) {
@@ -221,7 +223,6 @@
struct subbrep_object_data *obj = (struct subbrep_object_data
*)BU_PTBL_GET(subbreps, i);
if (obj->params->bool_op == 'u') {
bu_ptbl_ins(subbreps_tree, (long *)obj);
- bu_log("obj: %s\n", bu_vls_addr(obj->key));
subbrep_assemble_boolean_tree(&ps, subbreps_tree, obj);
}
}
Modified: brlcad/trunk/src/libbrep/shape_recognition_planar.cpp
===================================================================
--- brlcad/trunk/src/libbrep/shape_recognition_planar.cpp 2015-03-11
01:01:41 UTC (rev 64363)
+++ brlcad/trunk/src/libbrep/shape_recognition_planar.cpp 2015-03-11
01:29:53 UTC (rev 64364)
@@ -36,8 +36,6 @@
bu_vls_sprintf(data->planar_obj->key, "%s", bu_vls_addr(data->key));
data->planar_obj->type = PLANAR_VOLUME;
- std::cout << "subplanar_init: " << bu_vls_addr(data->key) << "\n";
-
data->planar_obj->local_brep = ON_Brep::New();
std::map<int, int> face_map;
std::map<int, int> surface_map;
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
Dive into the World of Parallel Programming The Go Parallel Website, sponsored
by Intel and developed in partnership with Slashdot Media, is your hub for all
things parallel software development, from weekly thought leadership blogs to
news, videos, case studies, tutorials and more. Take a look and join the
conversation now. http://goparallel.sourceforge.net/
_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/brlcad-commits