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

Fix crash on invalid mesh preview in Rhino #161

Merged
merged 1 commit into from
May 14, 2020

Conversation

adecler
Copy link
Member

@adecler adecler commented May 14, 2020

Issues addressed by this PR

Closes #160

Faces are added to the Rhino mesh if the vertices exist (well, the index exists). Faces not added will trigger a warning:

image

Test files

See issue for test file

Additional comments

@epignatelli , I am on your turf here so I hope I don't collide with your current plans (doesn't look like I do given sprint minutes). If I do, feel free to put this on hold. Also happy for you to use a different strategy to solve the issue if you feel this is creating side effects on the normal use of this toolkit.

@adecler adecler added the type:bug Error or unexpected behaviour label May 14, 2020
@adecler adecler added this to the BHoM 3.2 β MVP milestone May 14, 2020
@adecler adecler requested review from pawelbaran and epignatelli May 14, 2020 07:13
@adecler adecler self-assigned this May 14, 2020
Copy link
Member

@epignatelli epignatelli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @adecler !

I also found a small bug in Grasshopper when rendering Mesh wires.
Meshes are rendered even if there are no vertices, I'll raise a pr there as well.

@epignatelli epignatelli merged commit b235044 into master May 14, 2020
@epignatelli epignatelli deleted the Rhinoceros_Toolkit-#160-FixRhinoPreviewCrash branch May 14, 2020 08:16
@epignatelli
Copy link
Member

Actually, no, I take that back. We never perform checks in the BH.Engine.Grasshopper.Compute.DrawRhinoWires method, so I'd leave it like that and delegate the validity of the geometry just when we convert it!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:bug Error or unexpected behaviour
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Rhinoceros_Toolkit: Preview of invalid mesh crashes Rhino
2 participants