Revision: 78157
http://sourceforge.net/p/brlcad/code/78157
Author: starseeker
Date: 2021-02-01 14:15:31 +0000 (Mon, 01 Feb 2021)
Log Message:
-----------
Turn on the halting criteria for the -r flag (matrices above regions.)
Modified Paths:
--------------
brlcad/trunk/src/libged/npush/npush.cpp
Modified: brlcad/trunk/src/libged/npush/npush.cpp
===================================================================
--- brlcad/trunk/src/libged/npush/npush.cpp 2021-01-31 19:35:44 UTC (rev
78156)
+++ brlcad/trunk/src/libged/npush/npush.cpp 2021-02-01 14:15:31 UTC (rev
78157)
@@ -532,16 +532,12 @@
case OP_DB_LEAF:
- // If we're too deep, we're no longer creating instances to
manipulate
- if (s->max_depth && (depth > s->max_depth)) {
- return;
- }
-
// Don't consider the leaf it if doesn't exist (TODO - is this
always
// what we want to do when pushing?)
if ((dp=db_lookup(s->wdbp->dbip, tp->tr_l.tl_name, LOOKUP_NOISY))
== RT_DIR_NULL)
return;
+
/* Update current matrix state to reflect the new branch of
* the tree. Either we have a local matrix, or we have an
* implicit IDN matrix. */
@@ -626,6 +622,20 @@
(*tree_altered) = true;
}
+
+ // If we're at max depth, we're done creating instances to
manipulate
+ // on this tree branch.
+ if (s->max_depth && (depth == s->max_depth)) {
+ return;
+ }
+
+ /* If we're stopping at regions and this is a region, we're done. */
+ if ((dp->d_flags & RT_DIR_REGION) && s->stop_at_regions) {
+ /* Done with branch - put back the old matrix state */
+ MAT_COPY(*curr_mat, om);
+ return;
+ }
+
/* Process */
tree_update_walk(*dpii, depth, curr_mat, client_data);
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