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

Distinguish raycast rays that don't intersect surfaces #49

Closed
TomFarley opened this issue Nov 7, 2019 · 1 comment
Closed

Distinguish raycast rays that don't intersect surfaces #49

TomFarley opened this issue Nov 7, 2019 · 1 comment

Comments

@TomFarley
Copy link
Collaborator

Currently if a raycast point passes through a port or hole in the CAD model, the length of the returned ray is a function of the CAD dimensions and can be confusing to the user. It would be helpful if these ray lengths and end coords are returned as eg nans.

@ssilburn
Copy link
Collaborator

Hi Tom,

This is added in v2.5 - there is a new boolean keyworkd argument to raycast_sightlines() called "inersecting_only" - if you set this to True, rays which don't hit the CAD geometry will get NaN end coordinates and lengths. The default behaviour is still the same (default value of intersecting_only is False) because (1) to not break backwards compatibility, and (2) because the original behaviour is the desirable one in other uses cases e.g. generating tomography matrices.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants