Along the boresight (-z) between the distances (a point ahead of the apex).
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| real(kind=wp), | intent(in) | :: | point(3) |
in the cone's frame (scene units) |
||
| real(kind=wp), | intent(in), | optional | :: | min_distance |
along the boresight (scene units) |
|
| real(kind=wp), | intent(in), | optional | :: | max_distance |
along the boresight (scene units) |
pure logical function in_range(point, min_distance, max_distance) real(wp), intent(in) :: point(3) !! in the cone's frame (scene units) real(wp), intent(in), optional :: min_distance, max_distance !! along the boresight (scene units) real(wp) :: d d = -point(3) in_range = d >= 0.0_wp if (present(min_distance)) in_range = in_range .and. d >= min_distance if (present(max_distance)) in_range = in_range .and. d <= max_distance end function in_range