Skip to content

Commit

Permalink
merging RELEASE branch to STABLE branch, r75050 through r75561
Browse files Browse the repository at this point in the history
svn:revision:75562
svn:branch:STABLE
svn:account:starseeker
  • Loading branch information
starseeker committed Apr 23, 2020
2 parents e670046 + 12d9a62 commit 1c6f874
Show file tree
Hide file tree
Showing 21 changed files with 464 additions and 5,481 deletions.
5,450 changes: 82 additions & 5,368 deletions ChangeLog

Large diffs are not rendered by default.

12 changes: 12 additions & 0 deletions NEWS
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,18 @@ first and are grouped by release. Each release also includes optional
descriptive text that emphasizes or further describes significant
changes made. See document footer for additional details.

----------------------------------------------------------------------
--- 2020-04-22 Release 7.30.8 ---
----------------------------------------------------------------------

* improved behavior of MGED overlap checker GUI - Nick Reed
* fixed startup dimensions of overlap checker window - Nick Reed
* fixed rtedge line drawing color when using -W flag - Cliff Yapp
* added -F option to lint cmd to test specifc solid types - Cliff Yapp
* added support to MGED for zooming with mouse wheel - Cliff Yapp
* fixed solid editing wireframe drawing in MGED - Nick Reed
* added .r suffixes to region names in 3dm-g conversion - Cliff Yapp


----------------------------------------------------------------------
--- 2020-03-19 Release 7.30.6 ---
Expand Down
2 changes: 1 addition & 1 deletion README
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
BRL-CAD
Release 7.30.6
Release 7.30.8
http://brlcad.org/

BRL-CAD is a powerful cross-platform open source combinatorial
Expand Down
64 changes: 48 additions & 16 deletions doc/docbook/system/mann/lint.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
<arg choice="opt" rep="norepeat">-C</arg>
<arg choice="opt" rep="norepeat">-M</arg>
<arg choice="opt" rep="norepeat">-I</arg>
<arg choice="opt" rep="norepeat">-F "filters"</arg>
<arg choice="opt" rep="norepeat"><replaceable>ObjectName</replaceable></arg>
</cmdsynopsis>
</refsynopsisdiv>
Expand Down Expand Up @@ -82,45 +83,76 @@
</para>
</listitem>
</varlistentry>

<varlistentry>
<term><option>-F</option>, <option>--filter</option></term>
<listitem>
<para>
Apply search command style filters to the set of objects to be tested. Allows,
(for example) a user to test only brep objects and not bot objects or only objects
matching a particular name pattern. Does not impact the checks for missing or
cylic geometry - the underlying search mechanism assumes inputs do not have those
particular categories of problem and thus can't be reliably applied in those cases.
</para>
</listitem>
</varlistentry>
</variablelist>
</refsection>

<refsection xml:id="examples"><title>EXAMPLES</title>

<example>
<title>Examine entire database for all defect categories</title>

<para>
<prompt>mged&gt; </prompt><userinput>lint</userinput>
<literallayout class="normal">
Checking for cyclic paths...
Checking for references to non-extant objects...
Checking for invalid objects...
Found cyclic paths:
/c1/c2/c1
/c2/c1/c2
Found references to missing objects:
invalid_dsp_missing_binary_obj.s/missing_binary_object.s
invalid_dsp_missing_file.s/missing_file.data
invalid_extrude_missing_sketch.s/missing_sketch.s
missingentry.c/missing.s
Found invalid objects:
nonsolid.bot[bot] failed solidity test, but BoT type is RT_BOT_SOLID

</literallayout>
</para>
</example>

<example>
<title>Examine a single geometry object for validity</title>
<title>Check the validity of a single geometry object</title>

<para>
<prompt>mged&gt; </prompt><userinput>lint -I nonsolid.bot</userinput>
<literallayout class="normal">
Checking for invalid objects...
Found invalid objects:
nonsolid.bot[bot] failed bot solid test
nonsolid.bot[bot] failed solidity test, but BoT type is RT_BOT_SOLID

</literallayout>
</para>
</example>

<example>
<title>Examine entire database for all defect categories</title>
<title>Examine all non-BoT objects in the database matching the name pattern "*_1.*" for invalidity</title>

<para>
<prompt>mged&gt; </prompt><userinput>lint</userinput>
<prompt>mged&gt; </prompt><userinput>lint -F "! -type bot -name *_1.*"</userinput>
<literallayout class="normal">
Checking for cyclic paths...
Checking for references to non-extant objects...
Checking for invalid objects...
Found cyclic paths:
/c1/c2/c1
/c2/c1/c2
Found references to missing objects:
invalid_dsp_missing_binary_obj.s/missing_binary_object.s
invalid_dsp_missing_file.s/missing_file.data
invalid_extrude_missing_sketch.s/missing_sketch.s
missingentry.c/missing.s
Found invalid objects:
nonsolid.bot[bot] failed bot solid test
Brep_1.s[brep] failed OpenNURBS validity test
brep.m_L[27] loop is not valid.
end of brep.m_T[loop.m_ti[5]=147]=(0,-1.309) and start
of brep.m_T[loop.m_ti[6]=148]=(0,-5.63995e-08) do not match.
brep.m_F[25] face is not valid.
brep.m_L[face.m_li[0]=27] is not valid.
ON_Brep.m_F[25] is invalid.

</literallayout>
</para>
Expand Down
2 changes: 1 addition & 1 deletion include/conf/PATCH
Original file line number Diff line number Diff line change
@@ -1 +1 @@
6
8
6 changes: 3 additions & 3 deletions misc/CMake/BRLCAD_Util.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -85,14 +85,14 @@ function(message)
# optional arg, so we extract it and test.
list(GET ARGV 0 MessageType)

if (MessageType STREQUAL FATAL_ERROR OR MessageType STREQUAL SEND_ERROR OR MessageType STREQUAL WARNING OR MessageType STREQUAL AUTHOR_WARNING OR MessageType STREQUAL STATUS)
if (MessageType STREQUAL FATAL_ERROR OR MessageType STREQUAL SEND_ERROR OR MessageType STREQUAL WARNING OR MessageType STREQUAL AUTHOR_WARNING OR MessageType STREQUAL STATUS OR MessageType STREQUAL CHECK_START OR MessageType STREQUAL CHECK_PASS OR MessageType STREQUAL CHECK_FAIL )
list(REMOVE_AT ARGV 0)
_message(${MessageType} "${ARGV}")
file(APPEND "${BRLCAD_BINARY_DIR}/CMakeFiles/CMakeOutput.log" "${MessageType}: ${ARGV}\n")
else (MessageType STREQUAL FATAL_ERROR OR MessageType STREQUAL SEND_ERROR OR MessageType STREQUAL WARNING OR MessageType STREQUAL AUTHOR_WARNING OR MessageType STREQUAL STATUS)
else ()
_message("${ARGV}")
file(APPEND "${BRLCAD_BINARY_DIR}/CMakeFiles/CMakeOutput.log" "${ARGV}\n")
endif (MessageType STREQUAL FATAL_ERROR OR MessageType STREQUAL SEND_ERROR OR MessageType STREQUAL WARNING OR MessageType STREQUAL AUTHOR_WARNING OR MessageType STREQUAL STATUS)
endif ()

# ~10% slower alternative that avoids adding '--' to STATUS messages
# execute_process(COMMAND ${CMAKE_COMMAND} -E echo "${ARGV}")
Expand Down
7 changes: 7 additions & 0 deletions misc/debian/changelog
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
brlcad (7.30.8-0) unstable; urgency=low

* update brlcad version

-- Cliff Yapp <cyapp@brlcad.org> Wed, 13 Apr 2020 05:34:29 UTC


brlcad (7.30.6-0) unstable; urgency=low

* update brlcad version
Expand Down
2 changes: 1 addition & 1 deletion misc/macosx/Resources/ReadMe.rtfd/TXT.rtf
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
\f0\i\b\fs72 \cf0 README
\fs36 \
\f1\i0\b0\fs28 This is BRL-CAD 7.30.6 for Mac OS X. Please send any bugs, comments, questions, or suggestions to the project website.\
\f1\i0\b0\fs28 This is BRL-CAD 7.30.8 for Mac OS X. Please send any bugs, comments, questions, or suggestions to the project website.\
\fs22 \
Expand Down
2 changes: 1 addition & 1 deletion misc/macosx/Resources/Welcome.rtfd/TXT.rtf
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
\margl1440\margr1440\vieww8020\viewh6280\viewkind0
\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\ql\qnatural

\f0\fs22 \cf0 This installer will guide you through the installation of BRL-CAD 7.30.6 for Mac OS X and Darwin.\
\f0\fs22 \cf0 This installer will guide you through the installation of BRL-CAD 7.30.8 for Mac OS X and Darwin.\
\
This distribution of BRL-CAD requires approximately 500 MB of available disk space and does not include source code.\
\
Expand Down
48 changes: 48 additions & 0 deletions regress/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -235,6 +235,54 @@ set(regress_outfiles
dsp-2-5.log
dsp-2-5.pix
dsp-2-5.rt.pix
dsp-3-1.bw
dsp-3-1.dsp
dsp-3-1.g
dsp-3-1.log
dsp-3-1.pix
dsp-3-1.rt.pix
dsp-3-2.bw
dsp-3-2.dsp
dsp-3-2.g
dsp-3-2.log
dsp-3-2.pix
dsp-3-2.rt.pix
dsp-3-3.bw
dsp-3-3.dsp
dsp-3-3.g
dsp-3-3.log
dsp-3-3.pix
dsp-3-3.rt.pix
dsp-3-4.bw
dsp-3-4.dsp
dsp-3-4.g
dsp-3-4.log
dsp-3-4.pix
dsp-3-4.rt.pix
dsp-3-5.bw
dsp-3-5.dsp
dsp-3-5.g
dsp-3-5.log
dsp-3-5.pix
dsp-3-5.rt.pix
dsp-3-6.bw
dsp-3-6.dsp
dsp-3-6.g
dsp-3-6.log
dsp-3-6.pix
dsp-3-6.rt.pix
dsp-3-7.bw
dsp-3-7.dsp
dsp-3-7.g
dsp-3-7.log
dsp-3-7.pix
dsp-3-7.rt.pix
dsp-3-8.bw
dsp-3-8.dsp
dsp-3-8.g
dsp-3-8.log
dsp-3-8.pix
dsp-3-8.rt.pix
dsp.log
gqa.adj_air.plot3
gqa.exp_air.plot3
Expand Down
70 changes: 66 additions & 4 deletions src/libgcv/plugins/rhino/rhino_read.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,41 @@ comb_to_region(db_i &db, const std::string &name)
bu_bomb("db_lookup() failed");
}

static void
comb_region_name_check(std::map<const directory *, std::string> &renamed, db_i &db, const std::string &name)
{
RT_CK_DBI(&db);
// If name doesn't have a .r suffix, add it
struct bu_vls ext = BU_VLS_INIT_ZERO;
bool add_ext = false;
if (bu_path_component(&ext, name.c_str(), BU_PATH_EXT)) {
if (!BU_STR_EQUAL(bu_vls_cstr(&ext), ".r")) {
// Have an ext, but not the right one - add .r
add_ext = true;
}
} else {
// Don't have an ext - add it
add_ext = true;
}
bu_vls_free(&ext);

if (!add_ext) {
return;
}

struct bu_vls nname = BU_VLS_INIT_ZERO;
bu_vls_sprintf(&nname, "%s.r", name.c_str());

directory * const dir = db_lookup(&db, name.c_str(), true);
if (dir == RT_DIR_NULL) {
return;
}
std::pair<const directory *, std::string> rpair = std::make_pair(dir, name);
if (db_rename(&db, dir, bu_vls_cstr(&nname))){
return;
}
renamed.insert(rpair);
}

struct UuidCompare {
bool operator()(const ON_UUID &left, const ON_UUID &right) const
Expand Down Expand Up @@ -699,6 +734,7 @@ import_model_layers(rt_wdb &wdb, const ONX_Model &model,
HIDDEN void
polish_output(const gcv_opts &gcv_options, db_i &db)
{
std::map<const directory *, std::string> renamed;
bu_ptbl found = BU_PTBL_INIT_ZERO;
AutoPtr<bu_ptbl, db_search_free> autofree_found(&found);

Expand All @@ -715,17 +751,25 @@ polish_output(const gcv_opts &gcv_options, db_i &db)
db_search_free(&found);
BU_PTBL_INIT(&found);

if (0 > db_search(&found, DB_SEARCH_RETURN_UNIQ_DP,
"-type comb -attr rgb -not -above -attr rgb -or -attr shader -not -above -attr shader",
0, NULL, &db, NULL))
// Set region flags, add .r suffix to regions if not already present
renamed.clear();
const char *reg_search = "-type comb -attr rgb -not -above -attr rgb -or -attr shader -not -above -attr shader";
if (0 > db_search(&found, DB_SEARCH_RETURN_UNIQ_DP, reg_search, 0, NULL, &db, NULL))
bu_bomb("db_search() failed");
bu_ptbl found_instances = BU_PTBL_INIT_ZERO;
AutoPtr<bu_ptbl, db_search_free> autofree_found_instances(&found_instances);
if (0 > db_search(&found_instances, DB_SEARCH_TREE, reg_search, 0, NULL, &db, NULL))
bu_bomb("db_search() failed");

if (BU_PTBL_LEN(&found)) {
directory **entry;

for (BU_PTBL_FOR(entry, (directory **), &found)) {

comb_to_region(db, (*entry)->d_namep);

comb_region_name_check(renamed, db, (*entry)->d_namep);

if (gcv_options.randomize_colors) {
// random colors mode: TODO: move this into a filter after 7.26.0
std::string rgb;
Expand All @@ -742,11 +786,29 @@ polish_output(const gcv_opts &gcv_options, db_i &db)
}
}

// Update any combs that referred to old region names to reference the new ones instead
if (BU_PTBL_LEN(&found_instances)) {
db_full_path **entry;
for (BU_PTBL_FOR(entry, (db_full_path **), &found_instances)) {
struct directory *ec = DB_FULL_PATH_CUR_DIR(*entry);
struct directory *ep = (*entry)->fp_names[(*entry)->fp_len - 2];
std::map<const directory *, std::string>::iterator rentry = renamed.find(ec);
if (rentry == renamed.end()) {
continue;
}
bu_ptbl stack = BU_PTBL_INIT_ZERO;
AutoPtr<bu_ptbl, bu_ptbl_free> autofree_stack(&stack);
if (!db_comb_mvall(ep, &db, rentry->second.c_str(), ec->d_namep, &stack))
bu_bomb("db_comb_mvall() failed");
}
}
db_search_free(&found_instances);

// rename shapes after their parent layers
db_search_free(&found);
BU_PTBL_INIT(&found);
std::map<const directory *, std::string> renamed;

renamed.clear();
if (0 > db_search(&found, DB_SEARCH_TREE, "-type shape", 0, NULL, &db, NULL))
bu_bomb("db_search() failed");

Expand Down
2 changes: 1 addition & 1 deletion src/libged/draw.c
Original file line number Diff line number Diff line change
Expand Up @@ -577,7 +577,7 @@ _ged_cvt_vlblock_to_solids(struct ged *gedp, struct bn_vlblock *vbp, const char
if (BU_LIST_IS_EMPTY(&(vbp->head[i])))
continue;
snprintf(namebuf, 64, "%s%lx", shortname, vbp->rgb[i]);
invent_solid(gedp->ged_gdp->gd_headDisplay, gedp->ged_wdbp->dbip, gedp->ged_create_vlist_solid_callback, gedp->ged_free_vlist_callback, namebuf, &vbp->head[i], vbp->rgb[i], copy, 0.0, 0, gedp->freesolid, 0);
invent_solid(gedp->ged_gdp->gd_headDisplay, gedp->ged_wdbp->dbip, gedp->ged_create_vlist_solid_callback, gedp->ged_free_vlist_callback, namebuf, &vbp->head[i], vbp->rgb[i], copy, 1.0, 0, gedp->freesolid, 0);
}
}

Expand Down
Loading

0 comments on commit 1c6f874

Please sign in to comment.