Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge changes from BRL-CAD Main Repo #18

Merged
merged 216 commits into from
Dec 16, 2021
Merged

Conversation

treydinges
Copy link
Owner

No description provided.

…and memory, but also not proceeding if we can't read next successfully.
…s potentially needed by some ifdef 0 code, which was subsequently removed - unused.
Sean spotted this, and it looks like it may have been a significant
systematic mistake in my early NURBS brep coding.  ON_SimpleArray can't
always be used - per opennurbs_array.h, ON_SimpleArray "should not be
used for arrays of classes that require explicit construction,
destruction, or copy operators."  That probably means we've got a lot of
inappropriate uses of ON_SimpleArray at play.  I tended to try and treat
pointers to ON_* objects as being inserted into and managed by
ON_SimpleArray essentially as if they were C arrays of pointers, and
that looks to be incorrect.  Good chance this is the root cause behind a
lot of the more obscure memory issues clang static analyzer is finding
with the various brep related codes...
Previous problem wasn't quite what I thought - assignment was indeed
making a full copy, so we also need to delete.  Also need a few more
SimpleArray -> ClassArray switches.
…t seem to be in a working state and hasn't been worked on much since 2009.
…y we can clear by a combination of trimming and small changes.
starseeker and others added 29 commits December 15, 2021 10:42
CID 1488594 I think this might be a false positive, as CLAMP should be
keeping pl->blades within bounds, but go ahead and also make sure blade
never gets to BLADE_MAX to see if that helps.
CID 1487758 - Need to close fd if we got it from open()
CID 1488217 If we are representing booleans with a single char, need a
more convenient way to get the corresponding db_opt_t to avoid getting
into trouble with out-of-bounds access issues.
CID 1488266 fb_rect.c:158 - overrunning array of 24576 bytes at byte
offset 73725
CID 1494729
CID 1488493 Coverity doesn't like doing strlen on the fread results due
to possibly not being NULL terminated.  I think this may be a false
positive?  I would expect the memset on the buffer to give us a
guaranteed null at buf[BUFFER_SIZE]...
CID 1488763 If stash->connection is already closed, don't keep working
with it.
CID 1488494 - if c == next_code == 4096, then Expand(c) triggers an
OVERRUN condition.
…ed failing. Try increasing table size, and use bu_log to print the error code (Message is mangling the number)
Update to art with a slew of significant changes from Chris McGregor

This adds support for the set command to control the number of samples, it lets are utilize OSL shaders from appleseed that are set on objects via material objects (optical "OSL" property), and it should support most of the RTUIF commands (e.g., az/el) although the code was reverted to a +y coordinate frame which results in a 90-degree rotated output image.  Most significant in this pull is the conversion to registering each region individually as an appleseed object, so material properties and color can be applied per-object.  There is one big performance-impacting hack in the code -- a per ray string comparison.  Current librt rt_shootray() hit callback is initialized with the whole scene, but needs to report only hits for a single specific object at a time.  Hack was to check if it's the right object by way of a string path-to-region comparison.  Needs separate per-object rtip's or a numeric handle (e.g., pointer) to each region otherwise (depending on whether we think librt or appleseed's spatial partitioning is faster).  Outstanding work from Chris.
CID 1488969 - Per Coverity: internal representation of local output
escapes into output_file, but is destroyed when it exits scope.  Make a
C copy of the string for subsequent use, and free it when no longer
needed.
CID 1489084 - resource leak
@treydinges treydinges merged commit 3f0125b into treydinges:main Dec 16, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants