Skip to content

Commit

Permalink
have max elevation work with occlusion
Browse files Browse the repository at this point in the history
  • Loading branch information
robotastic committed Feb 4, 2025
1 parent 0635b0b commit c8236c5
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions skyscan-c2/c2_pub_sub.py
Original file line number Diff line number Diff line change
Expand Up @@ -467,12 +467,15 @@ def _elevation_check(self: Any, azimuth: float, elevation: float) -> bool:
if (obj["azimuth"] > azimuth) or (i == len(self.occlusion_mapping) - 1):

# If the Occlusion Point elevation is greater than the current elevation, then it is occluded.
if obj["elevation"] > elevation:
return False
else:
if self.max_tilt > elevation > obj["elevation"]:
return True
else:
return False
break
return True
if self.min_tilt > elevation:
return True
else:
return False
else:
return self.min_tilt <= elevation <= self.max_tilt

Expand Down

0 comments on commit c8236c5

Please sign in to comment.